diff --git a/src/NetscriptFunctions.ts b/src/NetscriptFunctions.ts index 6d7fa2399..2a6efef8e 100644 --- a/src/NetscriptFunctions.ts +++ b/src/NetscriptFunctions.ts @@ -1628,6 +1628,7 @@ export function NetscriptFunctions(workerScript: WorkerScript): NS { return cost; }, purchaseServer: function (aname: any, aram: any): any { + if (arguments.length !== 2) throw makeRuntimeErrorMsg("purchaseServer", "Takes 2 arguments"); const name = helper.string("purchaseServer", "name", aname); const ram = helper.number("purchaseServer", "ram", aram); updateDynamicRam("purchaseServer", getRamCost(Player, "purchaseServer"));