...
|
...
|
@@ -460,18 +460,21 @@ class Home extends Base { |
|
|
$datas = db()->cache(3600)->all(emailSql::getValues(['email'=>$emails],'`id`,`email`,`pwd_error`'));
|
|
|
foreach ($datas as $k=>$v){
|
|
|
if(!$v['pwd_error']){
|
|
|
$blacklist = app()->request('blacklist');
|
|
|
if(is_array($blacklist)){
|
|
|
$blacklist = [
|
|
|
'emails' => $blacklist['emails']??[],
|
|
|
'domain' => $blacklist['domain']??[],
|
|
|
];
|
|
|
// 黑名单,7天过期时间
|
|
|
redis()->set('blacklist:'.$v['id'],$blacklist,86400*7);
|
|
|
}
|
|
|
// 删除
|
|
|
if(!$blacklist||(empty($blacklist['emails'])&&empty($blacklist['domain']))){
|
|
|
redis()->delete('blacklist:'.$v['id']);
|
|
|
if(app()->requestHas('blacklist')){
|
|
|
$blacklist = app()->request('blacklist');
|
|
|
if(is_array($blacklist)){
|
|
|
$blacklist = [
|
|
|
'emails' => $blacklist['emails']??[],
|
|
|
'domain' => $blacklist['domain']??[],
|
|
|
];
|
|
|
// 黑名单,7天过期时间
|
|
|
redis()->set('blacklist:'.$v['id'],$blacklist,86400*7);
|
|
|
}
|
|
|
// 删除
|
|
|
if(!$blacklist||(empty($blacklist['emails'])&&empty($blacklist['domain']))){
|
|
|
redis()->delete('blacklist:'.$v['id']);
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
redis()->rPush('sync_email_lists', $v['id']);
|
...
|
...
|
|