From 6ef7b6b2d4390984d5fbf07c297c87758a8547a8 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sat, 9 Mar 2024 15:38:05 +0900 Subject: separate the time when ranking is shown again and the time when the quiz is finished --- services/app/src/Models/Quiz.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/services/app/src/Models/Quiz.php b/services/app/src/Models/Quiz.php index 5546646..5e2cda6 100644 --- a/services/app/src/Models/Quiz.php +++ b/services/app/src/Models/Quiz.php @@ -55,7 +55,8 @@ final class Quiz if ($now === null) { $now = new DateTimeImmutable('now', new DateTimeZone('UTC')); } - return $this->ranking_hidden_at <= $now && !$this->isFinished($now); + $rankingShownAgainAt = $this->finished_at->modify('+90 minutes'); + return $this->ranking_hidden_at <= $now && $now < $rankingShownAgainAt; } public static function create( -- cgit v1.2.3-70-g09d2