From f897d6db14e1f1f96952c4471f47df1884d31400 Mon Sep 17 00:00:00 2001 From: weiz Date: Tue, 28 Nov 2023 17:54:50 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9token=E4=B8=8D=E5=AD=98?= =?UTF-8?q?=E5=9C=A8=E6=98=AF=E7=9A=84=E6=8F=90=E7=A4=BA=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/api/http/middleware/LoginMiddleware.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/api/http/middleware/LoginMiddleware.php b/app/api/http/middleware/LoginMiddleware.php index bf69da41..ff36adca 100644 --- a/app/api/http/middleware/LoginMiddleware.php +++ b/app/api/http/middleware/LoginMiddleware.php @@ -40,7 +40,7 @@ class LoginMiddleware //不直接判断$isNotNeedLogin结果,使不需要登录的接口通过,为了兼容某些接口可以登录或不登录访问 if (empty($token) && !$isNotNeedLogin) { //没有token并且该地址需要登录才能访问, 指定show为0,前端不弹出此报错 - return JsonService::fail('请求参数缺token', [], 0, 0); + return JsonService::fail('用户信息不存在', [], 0, 0); } $userInfo = (new UserTokenCache())->getUserInfo($token);