This commit is contained in:
2025-08-15 18:18:38 +08:00
parent 9cd35ba01c
commit fa687d1106
2 changed files with 4 additions and 6 deletions

View File

@@ -50,7 +50,7 @@ class Frontend
$this->auth = Auth::instance();
$token = request()->header('token');
if ($token) {
if(request()->controller != 'app\czg\app\controller\LoginController' && request()->action != 'index'){} {
if(!strstr(request()->controller, 'LoginController') && request()->action != 'index') {
if(!$this->auth->init($token)) {
$this->error('Token expiration', [], 401);
}