Allow precreated JSC executor init without applicationScript
Reviewed By: mmmulani Differential Revision: D3836643 fbshipit-source-id: 18937ef5b39ebe3b3fd743490f86e40ffa6ee015
This commit is contained in:
parent
e2cf37a5a6
commit
d6926c5468
|
@ -329,7 +329,7 @@ static NSThread *newJavaScriptThread(void)
|
|||
*JSContext = data.context;
|
||||
}
|
||||
RCTJSCExecutor *executor = [[RCTJSCExecutor alloc] initWithJSContextData:data];
|
||||
if (![executor _synchronouslyExecuteApplicationScript:applicationScript sourceURL:sourceURL JSContext:data.context error:error]) {
|
||||
if (applicationScript && ![executor _synchronouslyExecuteApplicationScript:applicationScript sourceURL:sourceURL JSContext:data.context error:error]) {
|
||||
return nil; // error has been set by _synchronouslyExecuteApplicationScript:
|
||||
}
|
||||
return executor;
|
||||
|
|
Loading…
Reference in New Issue