From ab26a8016d11ad09f35b44192d340398ce9f0113 Mon Sep 17 00:00:00 2001 From: syuilo Date: Fri, 24 Mar 2023 16:01:35 +0900 Subject: [PATCH] =?UTF-8?q?fix(server):=20=E7=A9=BA=E3=81=AE=E3=82=A2?= =?UTF-8?q?=E3=83=B3=E3=83=86=E3=83=8A=E3=81=8C=E4=BD=9C=E6=88=90=E3=81=A7?= =?UTF-8?q?=E3=81=8D=E3=82=8B=E3=81=AE=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 + packages/backend/src/server/api/endpoints/antennas/create.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a69c72e25e..37e8bf0f41 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,7 @@ ### Server - リモートユーザーのチャート生成を無効にするオプションを追加 +- 空のアンテナが作成できるのを修正 ## 13.10.2 diff --git a/packages/backend/src/server/api/endpoints/antennas/create.ts b/packages/backend/src/server/api/endpoints/antennas/create.ts index d147ddb7f1..9ee311ace9 100644 --- a/packages/backend/src/server/api/endpoints/antennas/create.ts +++ b/packages/backend/src/server/api/endpoints/antennas/create.ts @@ -79,7 +79,7 @@ export default class extends Endpoint { private globalEventService: GlobalEventService, ) { super(meta, paramDef, async (ps, me) => { - if (ps.keywords.length === 0) { + if ((ps.keywords.length === 0) || (ps.keywords[0].filter(x => x !== '').length === 0)) { throw new Error('invalid param'); }