From 2eb86e061935b68dc92626cb1ce7d8c1129d8d9d Mon Sep 17 00:00:00 2001 From: Nanaka Hiira <114819113+7ka-Hiira@users.noreply.github.com> Date: Sun, 3 Dec 2023 10:28:35 +0900 Subject: [PATCH] =?UTF-8?q?fix(backend):=20/emoji=E3=81=AB=E3=81=8A?= =?UTF-8?q?=E3=81=91=E3=82=8B=E6=8B=A1=E5=BC=B5=E5=AD=90=E3=81=AE=E5=89=8A?= =?UTF-8?q?=E9=99=A4=E6=96=B9=E6=B3=95=E3=82=92=E4=BF=AE=E6=AD=A3=20(#1254?= =?UTF-8?q?3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Acid Chicken (硫酸鶏) --- packages/backend/src/server/ServerService.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/backend/src/server/ServerService.ts b/packages/backend/src/server/ServerService.ts index 17c2a9352..bb41ab0e4 100644 --- a/packages/backend/src/server/ServerService.ts +++ b/packages/backend/src/server/ServerService.ts @@ -119,8 +119,8 @@ export class ServerService implements OnApplicationShutdown { return; } - const name = path.split('@')[0].replace('.webp', ''); - const host = path.split('@')[1]?.replace('.webp', ''); + const name = path.split('@')[0].replace(/\.webp$/i, ''); + const host = path.split('@')[1]?.replace(/\.webp$/i, ''); const emoji = await this.emojisRepository.findOneBy({ // `@.` is the spec of ReactionService.decodeReaction