From 8f0c206cd7e7da1d52d3bdd98cd861111671f6b4 Mon Sep 17 00:00:00 2001 From: Baoshuo Date: Sat, 28 Jan 2023 18:35:07 +0800 Subject: [PATCH] fix: hide score in test when score not exists --- web/app/libs/uoj-html-lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/app/libs/uoj-html-lib.php b/web/app/libs/uoj-html-lib.php index 66bb094..15bb957 100644 --- a/web/app/libs/uoj-html-lib.php +++ b/web/app/libs/uoj-html-lib.php @@ -485,7 +485,7 @@ class JudgmentDetailsPrinter { echo '

', 'Subtask #', $subtask_num, ': ', '

'; echo ''; - if ($this->styler->show_score) { + if ($this->styler->show_score && $subtask_score !== '') { echo '
'; echo ' ', $subtask_score, ' pts'; echo '
'; @@ -555,7 +555,7 @@ class JudgmentDetailsPrinter { } echo ''; - if ($this->styler->show_score) { + if ($this->styler->show_score && $test_score !== '') { echo '
'; echo ' ', $test_score, ' pts'; echo '
';