Browse Source

Prevent early reload from assertion crashing navigation (#2715)

* Prevent early reload from crashing navigation

* fix typo
frankenthumbs 6 years ago
parent
commit
a829283eba
1 changed files with 3 additions and 0 deletions
  1. 3
    0
      lib/ios/RNNEventEmitter.m

+ 3
- 0
lib/ios/RNNEventEmitter.m View File

57
 # pragma mark private
57
 # pragma mark private
58
 
58
 
59
 -(void)send:(NSString *)eventName body:(id)body {
59
 -(void)send:(NSString *)eventName body:(id)body {
60
+    if ([eventName isEqualToString:componentDidDisappear] && self.bridge == nil) {
61
+        return;
62
+    }
60
 	[self sendEventWithName:eventName body:body];
63
 	[self sendEventWithName:eventName body:body];
61
 }
64
 }
62
 
65