From bea6a9c290e11bbc75d504850ec075a8e8c9827a Mon Sep 17 00:00:00 2001 From: monoid Date: Fri, 27 Dec 2024 20:44:22 +0900 Subject: [PATCH] fix: bug on ParseQueryArray --- packages/server/src/route/util.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/server/src/route/util.ts b/packages/server/src/route/util.ts index bdc39f0..8266aab 100644 --- a/packages/server/src/route/util.ts +++ b/packages/server/src/route/util.ts @@ -7,7 +7,7 @@ export function ParseQueryNumber(s: string[] | string | undefined): number | und } export function ParseQueryArray(s: string[] | string | undefined) { const input = s ?? []; - const r = Array.isArray(input) ? input : [input]; + const r = Array.isArray(input) ? input : input.split(","); return r.map((x) => decodeURIComponent(x)); } export function ParseQueryArgString(s: string[] | string | undefined) {