Fix tons of typos

This commit is contained in:
Olivier Gagnon
2022-10-09 01:25:31 -04:00
parent f8a3a046de
commit f6f023eeb4
110 changed files with 212 additions and 207 deletions
+2 -2
View File
@@ -40,7 +40,7 @@ function wrapFunction(
const functionPath = tree.join(".");
const functionName = tree.pop();
if (typeof functionName !== "string") {
throw helpers.makeBasicErrorMsg(workerScript, "Failure occured while wrapping netscript api", "INITIALIZATION");
throw helpers.makeBasicErrorMsg(workerScript, "Failure occurred while wrapping netscript api", "INITIALIZATION");
}
const ctx = {
workerScript,
@@ -89,7 +89,7 @@ export function wrapAPILayer(
function setNestedProperty(root: any, value: unknown, ...tree: string[]): void {
let target = root;
const key = tree.pop();
if (!key) throw new Error("Failure occured while wrapping netscript api (setNestedProperty)");
if (!key) throw new Error("Failure occurred while wrapping netscript api (setNestedProperty)");
for (const branch of tree) {
target[branch] ??= {};
target = target[branch];