Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
9052bb8d2a
|
|
@ -49,9 +49,11 @@ class Frontend
|
|||
// 初始化会员鉴权实例
|
||||
$this->auth = Auth::instance();
|
||||
$token = request()->header('token');
|
||||
if ($token && $needLogin) {
|
||||
if(!$this->auth->init($token)) {
|
||||
$this->error('Token expiration', [], 401);
|
||||
if ($token) {
|
||||
if(request()->controller != 'app\czg\app\controller\LoginController' && request()->action != 'index'){} {
|
||||
if(!$this->auth->init($token)) {
|
||||
$this->error('Token expiration', [], 401);
|
||||
}
|
||||
}
|
||||
}else {
|
||||
if ($needLogin) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue