[更新]强制刷新验证码

This commit is contained in:
Anyon 2019-09-26 09:58:51 +08:00
parent 3aec231910
commit 3d119013a4

View File

@ -137,9 +137,7 @@ class CaptchaService
{
$_uni = is_string($uniqid) ? $uniqid : input('uniqid', '-');
$_val = Cache::tag('captcha')->get($_uni);
if (is_string($_val) && strtolower($_val) === strtolower($code)) {
Cache::tag('captcha')->rm($_uni);
return true;
} else return false;
Cache::tag('captcha')->rm($_uni);
return is_string($_val) && strtolower($_val) === strtolower($code);
}
}