diff --git a/src/NetscriptFunctions/Flags.ts b/src/NetscriptFunctions/Flags.ts index 1d08dc67b..2b9682c84 100644 --- a/src/NetscriptFunctions/Flags.ts +++ b/src/NetscriptFunctions/Flags.ts @@ -4,7 +4,7 @@ import { ScriptArg } from "../Netscript/ScriptArg"; import { NetscriptContext } from "../Netscript/APIWrapper"; type FlagType = StringConstructor | NumberConstructor | BooleanConstructor | StringConstructor[]; -type FlagsRet = { [key: string]: ScriptArg }; +type FlagsRet = { [key: string]: ScriptArg | string[] }; export function Flags(ctx: NetscriptContext | string[]): (data: unknown) => FlagsRet { const vargs = Array.isArray(ctx) ? ctx : ctx.workerScript.args; return (schema: unknown): FlagsRet => { diff --git a/src/ScriptEditor/NetscriptDefinitions.d.ts b/src/ScriptEditor/NetscriptDefinitions.d.ts index 1e7f4318a..06dc84e4d 100644 --- a/src/ScriptEditor/NetscriptDefinitions.d.ts +++ b/src/ScriptEditor/NetscriptDefinitions.d.ts @@ -6531,7 +6531,7 @@ export interface NS { * // {"_":[],"delay":0,"server":"foodnstuff","exclude":[],"help":true} * ``` */ - flags(schema: [string, string | number | boolean | string[]][]): { [key: string]: ScriptArg }; + flags(schema: [string, string | number | boolean | string[]][]): { [key: string]: ScriptArg | string[] }; /** * Share your computer with your factions.