wupengfei 2 年之前
父节点
当前提交
0b0eeb39db
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      application/api/controller/Base.php

+ 2 - 1
application/api/controller/Base.php

@@ -31,7 +31,7 @@ use think\Response;
  */
  */
 class Base extends Controller
 class Base extends Controller
 {
 {
-    protected $uid = 1;
+    protected $uid = 2;
 
 
     protected $page; // 页数
     protected $page; // 页数
     protected $page_num;
     protected $page_num;
@@ -47,6 +47,7 @@ class Base extends Controller
         $authorization = app()->request->header('Authorization');
         $authorization = app()->request->header('Authorization');
         //var_dump($authorization.'111');exit();
         //var_dump($authorization.'111');exit();
         if(empty($authorization) || $authorization == null){
         if(empty($authorization) || $authorization == null){
+            return true;
             $this->error('Token不存在,拒绝访问','',0);
             $this->error('Token不存在,拒绝访问','',0);
         }
         }
         $key = md5(config('app.jwt'));
         $key = md5(config('app.jwt'));