diff --git a/app/controller/api/Auth.php b/app/controller/api/Auth.php index a8a74493..e1c0407f 100755 --- a/app/controller/api/Auth.php +++ b/app/controller/api/Auth.php @@ -940,7 +940,7 @@ class Auth extends BaseController if ($code && ($info = app()->make(RoutineQrcodeRepository::class)->getRoutineQrcodeFindType($code))) { $auth['auth']['spread'] = $info['third_id']; } - if (!$user || empty($user['account'])) { + if (!$user || empty($user['account']) || empty($user['phone'])) { $uni = uniqid(true, false) . random_int(1, 100000000); $key = 'U' . md5(time() . $uni); Cache::set('u_try' . $key, ['id' => $authInfo['wechat_user_id'], 'type' => $authInfo['user_type'], 'spread' => $auth['auth']['spread'] ?? 0], 3600);