fix two cases where markUpdated was not properly called

This commit is contained in:
James Aguilar 2019-06-02 15:38:45 -04:00
parent 65331ab22e
commit 3ef9042051
2 changed files with 2 additions and 2 deletions

@ -1139,7 +1139,7 @@ function NetscriptFunctions(workerScript) {
var oldScript = destServer.scripts[i]; var oldScript = destServer.scripts[i];
oldScript.code = sourceScript.code; oldScript.code = sourceScript.code;
oldScript.ramUsage = sourceScript.ramUsage; oldScript.ramUsage = sourceScript.ramUsage;
oldScript.module = ""; oldScript.module.markUpdated();
return true; return true;
} }
} }

@ -534,7 +534,7 @@ export function loadAllRunningScripts() {
// Reset modules on all scripts // Reset modules on all scripts
for (let i = 0; i < server.scripts.length; ++i) { for (let i = 0; i < server.scripts.length; ++i) {
server.scripts[i].module = ""; server.scripts[i].markUpdated();
} }
if (skipScriptLoad) { if (skipScriptLoad) {