mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Temporarily add logs in TM initialization
Summary: Marketplace eagerly initializes a few NativeModules. These NativeModules are TurboModule compatible, and the device/user is in the TurboModule test. So these NativeModuels should be returned from the TurboModule system. However, for some reason, we end up doing a lookup on the `NativeModuleRegistry` for these NativeModules. This means that either: 1. The TurboModuleManager isn't attached to the CatalystInstance 2. The TurboModuleManager returned null from getModule. These logs will help us get to the bottom of what's going on. Changelog: [Internal] Reviewed By: JoshuaGross Differential Revision: D20260150 fbshipit-source-id: bb554ead412ad3b0fa7502b77f575365608ebc98
This commit is contained in:
committed by
Facebook Github Bot
parent
3a9fc7cbcf
commit
7ec9af0fcf
@@ -581,6 +581,13 @@ public class CatalystInstanceImpl implements CatalystInstance {
|
||||
if (getTurboModuleRegistry() != null) {
|
||||
TurboModule turboModule = getTurboModuleRegistry().getModule(moduleName);
|
||||
|
||||
// TODO(T46487253): Remove after task is closed
|
||||
FLog.e(
|
||||
ReactConstants.TAG,
|
||||
"CatalystInstanceImpl.getNativeModule: TurboModule "
|
||||
+ moduleName
|
||||
+ (turboModule == null ? " not" : "")
|
||||
+ " found");
|
||||
if (turboModule != null) {
|
||||
return (NativeModule) turboModule;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user