mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Back out "Allow the TurboModule system to create legacy modules"
Summary: Original commit changeset: be6f054556d1 Original Phabricator Diff: D45706884 ## Changelog: [iOS][Fixed] - Revert [TM][iOS] Allow the TurboModule system to create legacy modules Reviewed By: jacdebug Differential Revision: D45773198 fbshipit-source-id: ba6b6c136e74fde53af5c014d8223c4c7d1509db
This commit is contained in:
committed by
Facebook GitHub Bot
parent
dc913c1647
commit
ad116dad16
+1
-10
@@ -420,7 +420,7 @@ static Class getFallbackClassFromName(const char *name)
|
||||
|
||||
__block id<RCTBridgeModule> module = nil;
|
||||
|
||||
if ([self _shouldCreateObjCModule:moduleClass]) {
|
||||
if ([moduleClass conformsToProtocol:@protocol(RCTTurboModule)]) {
|
||||
__weak __typeof(self) weakSelf = self;
|
||||
dispatch_block_t work = ^{
|
||||
auto strongSelf = weakSelf;
|
||||
@@ -478,15 +478,6 @@ static Class getFallbackClassFromName(const char *name)
|
||||
return moduleHolder->getModule();
|
||||
}
|
||||
|
||||
- (BOOL)_shouldCreateObjCModule:(Class)moduleClass
|
||||
{
|
||||
if (RCTTurboModuleInteropEnabled()) {
|
||||
return [moduleClass conformsToProtocol:@protocol(RCTBridgeModule)];
|
||||
}
|
||||
|
||||
return [moduleClass conformsToProtocol:@protocol(RCTTurboModule)];
|
||||
}
|
||||
|
||||
/**
|
||||
* Given a NativeModule class, and its name, create and initialize it synchronously.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user