...
|
...
|
@@ -49,6 +49,13 @@ class SyncMail { |
|
|
protected $search = null;
|
|
|
|
|
|
/**
|
|
|
* 是否强制更新
|
|
|
* @var bool
|
|
|
*/
|
|
|
protected $isForceUpdate = false;
|
|
|
|
|
|
|
|
|
/**
|
|
|
* SyncMail constructor.
|
|
|
* @param int|string|array $email
|
|
|
* @throws \Exception
|
...
|
...
|
@@ -103,6 +110,14 @@ class SyncMail { |
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 强制更新本地数据
|
|
|
*/
|
|
|
public function forceUpdate(): void
|
|
|
{
|
|
|
$this->isForceUpdate = true;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 登录imap
|
|
|
* @throws \Exception
|
|
|
* @author:dc
|
...
|
...
|
@@ -262,6 +277,10 @@ class SyncMail { |
|
|
* @time 2024/11/12 14:17
|
|
|
*/
|
|
|
private function getFilterUid(array $uids, int $folder_id):array {
|
|
|
// 强制更新本地数据,不进行过滤
|
|
|
if($this->isForceUpdate){
|
|
|
return $uids;
|
|
|
}
|
|
|
foreach ($uids as $k=>$uid){
|
|
|
|
|
|
$num = redis()->get('h_'.$folder_id.'_'.$uid,function () use ($folder_id,$uid){
|
...
|
...
|
|