@ -125,6 +125,7 @@ $configs = array(
//源码下载:https://git.filesite.io/filesite/service-3rd
'service_3rd_api_domain' => 'https://service.filesite.io',
'service_3rd_api_key' => '你的密钥',
'sms_code_cache_time' => 600, //短信验证码缓存时长,单位:秒
);
@ -453,7 +453,8 @@ eof;
$rndCode_created = !empty($_SESSION['randSmsCode_created']) ? $_SESSION['randSmsCode_created'] : 0;
$current_time = time();
if (!empty($rndCode_created) && $current_time - $rndCode_created > 600) {
$max_cache_time = !empty(FSC::$app['config']['sms_code_cache_time']) ? FSC::$app['config']['sms_code_cache_time'] : 600;
if (!empty($rndCode_created) && $current_time - $rndCode_created > $max_cache_time) {
$rndCode = 0;
}