Commit a2412b8e authored by moriyoshi's avatar moriyoshi

Dispatch registerForRemoteNotifications on main thread to prevent runtime warnings

parent 858167ca
...@@ -293,7 +293,9 @@ RCT_EXPORT_METHOD(requestPermissions:(RCTPromiseResolveBlock)resolve rejecter:(R ...@@ -293,7 +293,9 @@ RCT_EXPORT_METHOD(requestPermissions:(RCTPromiseResolveBlock)resolve rejecter:(R
#endif #endif
} }
[[UIApplication sharedApplication] registerForRemoteNotifications]; dispatch_async(dispatch_get_main_queue(), ^{
[[UIApplication sharedApplication] registerForRemoteNotifications];
});
} }
RCT_EXPORT_METHOD(subscribeToTopic: (NSString*) topic) RCT_EXPORT_METHOD(subscribeToTopic: (NSString*) topic)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment