新增im消息回调修改

This commit is contained in:
2023-11-27 13:42:41 +08:00
parent 9acd0ae680
commit d3e819eb42
2 changed files with 9 additions and 7 deletions
-6
View File
@@ -1006,12 +1006,6 @@ class UserService extends BaseService
$result['message'] = "在线状态存储失败";
return $result;
}
// 添加缓存
$redis = $this->container->get(Redis::class);
$redis_key = "user_im_online_" . $user['user_id'];
$redis->set($redis_key,$msg_data['RequestTime'],3*60);
} elseif ($msg_data['Info']['Action'] == "Disconnect"){
// 点右上角退出/断网(如手机开启飞行模式)/微信切后台/杀掉微信进程
$time = strtotime($msg_data['RequestTime']) + 3*60;