Skip to content

Commit

Permalink
Check runtimeExecutor before calling onMainLoopIdle (#194)
Browse files Browse the repository at this point in the history
  • Loading branch information
colincarter committed Aug 20, 2024
1 parent 8733225 commit f55ebdb
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ public boolean queueIdle() {
final RuntimeExecutor runtimeExecutor = getReactApplicationContext()
.getCatalystInstance()
.getRuntimeExecutor();
V8Executor.onMainLoopIdle(runtimeExecutor);

if (runtimeExecutor != null) {
V8Executor.onMainLoopIdle(runtimeExecutor);
}

mLastMainLoopIdleCallbackTime = SystemClock.uptimeMillis();
}
return true;
Expand Down

0 comments on commit f55ebdb

Please sign in to comment.