Fix "[TM][JS] Forward NativeModule schema to __turboModuleProxy"

Summary: Changelog: [Internal]

Reviewed By: PeteTheHeat

Differential Revision: D22888030

fbshipit-source-id: cb2b47f51f6ad5a7397045ffe5b81c9e1e396250
This commit is contained in:
Ramanpreet Nara
2020-08-04 15:49:52 -07:00
committed by Facebook GitHub Bot
parent b5097c8dcd
commit 9728d04f96
+2 -1
View File
@@ -27,7 +27,8 @@ function requireModule<T: TurboModule>(name: string, schema?: ?$FlowFixMe): ?T {
}
if (turboModuleProxy != null) {
const module: ?T = turboModuleProxy(name, schema);
const module: ?T =
schema != null ? turboModuleProxy(name, schema) : turboModuleProxy(name);
return module;
}