From 030ab5f0ab1b4deda08fb93aa5e2f6a0fc544215 Mon Sep 17 00:00:00 2001 From: CounterFire2023 <136581895+CounterFire2023@users.noreply.github.com> Date: Wed, 27 Mar 2024 13:58:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A9=E5=8A=9B=E7=AE=B1=E5=AD=90,=20?= =?UTF-8?q?=E5=B0=86=E7=94=9F=E6=88=90=E7=9A=84=E7=AE=B1=E5=AD=90=E8=BF=94?= =?UTF-8?q?=E5=9B=9E=E7=BB=99=E5=AE=A2=E6=88=B7=E7=AB=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/controllers/chest.controller.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/controllers/chest.controller.ts b/src/controllers/chest.controller.ts index aceb0c5..e3a1239 100644 --- a/src/controllers/chest.controller.ts +++ b/src/controllers/chest.controller.ts @@ -113,9 +113,14 @@ class BoxController extends BaseController { if (chestsForUser.length === 0) { const newChest = generateNewChest(uid, user.activity, 1, ChestStatusEnum.LOCKED) await newChest.save() - } - return { - score, + return { + score: 0, + chests: [newChest.toJson()], + } + } else { + return { + score: 0, + } } }