Skip to content

Commit a6112ff

Browse files
committed
[captcha] if there is no captcha enabled, default to allowing things instead of denying them
1 parent d7660d2 commit a6112ff

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

core/Util/Captcha.php

+5-1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ public static function check(?string $bypass_if = null): bool
3131
return true;
3232
}
3333

34-
return (bool)send_event(new CheckCaptchaEvent())->passed;
34+
$passed = send_event(new CheckCaptchaEvent())->passed;
35+
if ($passed === null) {
36+
$passed = true;
37+
}
38+
return $passed;
3539
}
3640
}

0 commit comments

Comments
 (0)