diff --git a/webapp/src/Twig/TwigExtension.php b/webapp/src/Twig/TwigExtension.php index a496f540be..3a44fccb52 100644 --- a/webapp/src/Twig/TwigExtension.php +++ b/webapp/src/Twig/TwigExtension.php @@ -1065,9 +1065,9 @@ public function fileTypeIcon(string $type): string public function problemBadge(ContestProblem $problem, bool $grayedOut = false): string { - $rgb = Utils::convertToHex($problem->getColor() ?? '#ffffff'); + $rgb = Utils::convertToHex($problem->getColor() ?? '#ffffff'); if ($grayedOut) { - $rgb = 'whitesmoke'; + $rgb = Utils::convertToHex('whitesmoke'); } $background = Utils::parseHexColor($rgb); @@ -1095,9 +1095,9 @@ public function problemBadge(ContestProblem $problem, bool $grayedOut = false): public function problemBadgeMaybe(ContestProblem $problem, ScoreboardMatrixItem $matrixItem): string { - $rgb = Utils::convertToHex($problem->getColor() ?? '#ffffff'); + $rgb = Utils::convertToHex($problem->getColor() ?? '#ffffff'); if (!$matrixItem->isCorrect) { - $rgb = 'whitesmoke'; + $rgb = Utils::convertToHex('whitesmoke'); } $background = Utils::parseHexColor($rgb);