Fixed reachability

This commit is contained in:
Nick Lockwood
2015-04-20 08:31:15 -07:00
parent 2d5d55d17e
commit bbd5259586
6 changed files with 123 additions and 78 deletions

View File

@@ -25,6 +25,8 @@ static NSString *const RCTReachabilityStateCell = @"cell";
@synthesize bridge = _bridge;
RCT_EXPORT_MODULE()
static void RCTReachabilityCallback(__unused SCNetworkReachabilityRef target, SCNetworkReachabilityFlags flags, void *info)
{
RCTReachability *self = (__bridge id)info;
@@ -53,8 +55,6 @@ static void RCTReachabilityCallback(__unused SCNetworkReachabilityRef target, SC
}
}
RCT_EXPORT_MODULE()
#pragma mark - Lifecycle
- (instancetype)initWithHost:(NSString *)host
@@ -71,7 +71,7 @@ RCT_EXPORT_MODULE()
- (instancetype)init
{
return [self initWithHost:@"http://apple.com"];
return [self initWithHost:@"apple.com"];
}
- (void)dealloc