mirror of
https://github.com/status-im/react-native.git
synced 2025-01-27 17:54:48 +00:00
Fixing compiler warning
Summary: Compiler is giving a warning about an unused variable. Tested by compiling the source code and verifying the warning is removed. Closes https://github.com/facebook/react-native/pull/13819 Differential Revision: D5189680 Pulled By: shergin fbshipit-source-id: 89848fcd3e988d1c256b315cfa2ef60a62c2ad56
This commit is contained in:
parent
a3249650d6
commit
407b8b4d1f
@ -141,10 +141,13 @@ expectErrorBlock:(BOOL(^)(NSString *error))expectErrorBlock
|
|||||||
|
|
||||||
RCTSetLogFunction(defaultLogFunction);
|
RCTSetLogFunction(defaultLogFunction);
|
||||||
|
|
||||||
|
#if RCT_DEV
|
||||||
NSArray<UIView *> *nonLayoutSubviews = [vc.view.subviews filteredArrayUsingPredicate:[NSPredicate predicateWithBlock:^BOOL(id subview, NSDictionary *bindings) {
|
NSArray<UIView *> *nonLayoutSubviews = [vc.view.subviews filteredArrayUsingPredicate:[NSPredicate predicateWithBlock:^BOOL(id subview, NSDictionary *bindings) {
|
||||||
return ![NSStringFromClass([subview class]) isEqualToString:@"_UILayoutGuide"];
|
return ![NSStringFromClass([subview class]) isEqualToString:@"_UILayoutGuide"];
|
||||||
}]];
|
}]];
|
||||||
|
|
||||||
RCTAssert(nonLayoutSubviews.count == 0, @"There shouldn't be any other views: %@", nonLayoutSubviews);
|
RCTAssert(nonLayoutSubviews.count == 0, @"There shouldn't be any other views: %@", nonLayoutSubviews);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (expectErrorBlock) {
|
if (expectErrorBlock) {
|
||||||
RCTAssert(expectErrorBlock(error), @"Expected an error but nothing matched.");
|
RCTAssert(expectErrorBlock(error), @"Expected an error but nothing matched.");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user