From 20c0ddd958af7ed73282e5d8c6dc3f57198ba502 Mon Sep 17 00:00:00 2001 From: Baoshuo Date: Mon, 7 Nov 2022 07:33:11 +0800 Subject: [PATCH] fix(web/contest): UOJContest::userCanView --- web/app/models/UOJContest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/app/models/UOJContest.php b/web/app/models/UOJContest.php index 3bfad48..3ef5a3d 100644 --- a/web/app/models/UOJContest.php +++ b/web/app/models/UOJContest.php @@ -303,7 +303,7 @@ class UOJContest { ]; if ($this->userCanManage($user)) { - if ($this->userHasRegistered($user) && $this->progress() == CONTEST_IN_PROGRESS) { + if ($this->userHasRegistered($user) && $this->progress() == CONTEST_IN_PROGRESS && !$this->userHasMarkedParticipated($user)) { $cfg['ensure'] && redirectTo($this->getUri('/confirm')); return false; }