aboutsummaryrefslogtreecommitdiff
path: root/src/preamble.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/preamble.js')
-rw-r--r--src/preamble.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/preamble.js b/src/preamble.js
index fa86fca6..cb01994f 100644
--- a/src/preamble.js
+++ b/src/preamble.js
@@ -871,7 +871,8 @@ function removeRunDependency(id) {
clearInterval(runDependencyWatcher);
runDependencyWatcher = null;
}
- if (!calledRun) run();
+ // If run has never been called, and we should call run (INVOKE_RUN is true, and Module.noInitialRun is not false)
+ if (!calledRun && shouldRunNow) run();
}
}
Module['removeRunDependency'] = removeRunDependency;