Execute init task on thread pool executor
Reviewed By: foghina Differential Revision: D3522112 fbshipit-source-id: 8a0880d0e7bf3e0bce02c44e8d504f01ab47beb8
This commit is contained in:
parent
c3f2bba834
commit
c57eb94b34
|
@ -710,7 +710,7 @@ import static com.facebook.systrace.Systrace.TRACE_TAG_REACT_JAVA_BRIDGE;
|
|||
if (mReactContextInitAsyncTask == null) {
|
||||
// No background task to create react context is currently running, create and execute one.
|
||||
mReactContextInitAsyncTask = new ReactContextInitAsyncTask();
|
||||
mReactContextInitAsyncTask.execute(initParams);
|
||||
mReactContextInitAsyncTask.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, initParams);
|
||||
} else {
|
||||
// Background task is currently running, queue up most recent init params to recreate context
|
||||
// once task completes.
|
||||
|
|
Loading…
Reference in New Issue