fix(problem/remote): difficulty

This commit is contained in:
Baoshuo Ren 2023-01-19 11:47:35 +08:00
parent fbed1162c0
commit 4523109085
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A

View File

@ -58,7 +58,7 @@ class UOJRemoteProblem {
foreach ($dom->querySelectorAll('.tag-box') as &$elem) {
$matches = [];
if (preg_match('/\*([0-9]{3,4})/', trim($elem->innerHTML), $matches) !== false) {
if (preg_match('/\*([0-9]{3,4})/', trim($elem->innerHTML), $matches)) {
$difficulty = intval($matches[1]);
break;