From 488f34635794ec00ceead35548b06b67d80bce8e Mon Sep 17 00:00:00 2001 From: Ramin Date: Mon, 2 Jun 2025 20:13:05 +0330 Subject: [PATCH] fix you voted badge when poll is ended --- src/user/user.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/user/user.service.ts b/src/user/user.service.ts index 53aa309..11092e8 100644 --- a/src/user/user.service.ts +++ b/src/user/user.service.ts @@ -274,7 +274,7 @@ export class UserService { }, select: { endDate: true, options: true }, }) - if (!poll || (poll.endDate && poll.endDate < new Date())) { + if (!poll) { throw new PollNotFoundException() } const vote = await this.databaseService.vote.findFirst({