fix: 修复账号解绑bug

This commit is contained in:
Ying
2023-06-23 17:46:05 +08:00
parent 7b2d408745
commit b4b73ac2aa
3 changed files with 1 additions and 4 deletions

View File

@@ -237,7 +237,6 @@ class UserService
/** /**
* 退出登录 * 退出登录
* @return void * @return void
* @throws InvalidArgumentException
*/ */
public static function logout(): void public static function logout(): void
{ {

View File

@@ -211,13 +211,12 @@ class Third extends HomeController
} }
$where['type'] = $this->type; $where['type'] = $this->type;
$where['user_id'] = request()->cookie('uid'); $where['user_id'] = request()->userId;
if (UserThird::where($where)->delete()) { if (UserThird::where($where)->delete()) {
return $this->success('解除绑定成功!'); return $this->success('解除绑定成功!');
} }
} }
return $this->error(); return $this->error();
} }

View File

@@ -66,7 +66,6 @@ class IndexPermissions implements MiddlewareInterface
$userInfo = UserTokenService::isLogin(); $userInfo = UserTokenService::isLogin();
if (!empty($userInfo)) { if (!empty($userInfo)) {
if (in_array($action, $this->repeatLogin)) { if (in_array($action, $this->repeatLogin)) {
var_dump($this->JumpUrl);
return redirect($this->JumpUrl); return redirect($this->JumpUrl);
} }