Skip to content

Commit 188cbb0

Browse files
Peter Arganyfacebook-github-bot
Peter Argany
authored andcommitted
Reset module registry flag when resetting React Instance
Summary: D12911108 fixed a UBN race condition by adding a flag for module registry. This flag was never reset if react instance gets reset, causing an assert to fire in IG. Reviewed By: fkgozali Differential Revision: D13010651 fbshipit-source-id: e20453f3c546d759a58fd7fb93553f774410905f
1 parent 2bf0d54 commit 188cbb0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

React/CxxBridge/RCTCxxBridge.mm

+2
Original file line numberDiff line numberDiff line change
@@ -880,6 +880,7 @@ - (void)handleError:(NSError *)error
880880

881881
_loading = NO;
882882
_valid = NO;
883+
_moduleRegistryCreated = NO;
883884

884885
dispatch_async(dispatch_get_main_queue(), ^{
885886
if (self->_jsMessageThread) {
@@ -976,6 +977,7 @@ - (void)invalidate
976977
_loading = NO;
977978
_valid = NO;
978979
_didInvalidate = YES;
980+
_moduleRegistryCreated = NO;
979981

980982
if ([RCTBridge currentBridge] == self) {
981983
[RCTBridge setCurrentBridge:nil];

0 commit comments

Comments
 (0)