From 814f1882d88b8d7f33424eeaff146bb98d115e0f Mon Sep 17 00:00:00 2001 From: ghkkk090 Date: Sat, 10 Sep 2022 10:47:53 +0700 Subject: [PATCH] fix ghost stamp bug --- src/modules/ghost.ts | 23 +++++++++++++++++++++-- src/modules/terminal.ts | 6 ++++-- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/src/modules/ghost.ts b/src/modules/ghost.ts index fda1877..c3bb9b7 100644 --- a/src/modules/ghost.ts +++ b/src/modules/ghost.ts @@ -110,10 +110,29 @@ export default class GhostModule extends Module { } } - // Get all of the friend cars for the carId provided + // Get all of the challenger car for the carId provided except beated car + let checkBeatedCar = await prisma.carStampTarget.findMany({ + where: { + stampTargetCarId: body.carId, + recommended: false + }, + orderBy:{ + carId: 'asc' + } + }); + + let arrChallengerCarId = []; + for(let i=0; i