Fix workForFaction invalid worktype case

When invalid work type, the function should return false instead of true
This commit is contained in:
Qiyi Shan 2022-04-05 11:22:02 -04:00 committed by GitHub
parent acfd164927
commit b9caddeeef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1104,6 +1104,7 @@ export function NetscriptSingularity(
return true;
default:
workerScript.log("workForFaction", () => `Invalid work type: '${type}`);
return false;
}
return true;
},