作者 lyh

gx

@@ -65,7 +65,6 @@ class LoginController extends BaseController @@ -65,7 +65,6 @@ class LoginController extends BaseController
65 } 65 }
66 $data = $encrypt->unlock_url($this->param['code'], $info['values']); 66 $data = $encrypt->unlock_url($this->param['code'], $info['values']);
67 $data = json_decode($data, true); 67 $data = json_decode($data, true);
68 - @file_put_contents(storage_path('logs/lyh_error.log'), var_export($data, true) . PHP_EOL, FILE_APPEND);  
69 if(!isset($data['project_id']) && !isset($data['user_id'])){ 68 if(!isset($data['project_id']) && !isset($data['user_id'])){
70 $this->response('无效Code',Code::USER_ERROR); 69 $this->response('无效Code',Code::USER_ERROR);
71 } 70 }
@@ -22,7 +22,9 @@ class LoginAuthMiddleware @@ -22,7 +22,9 @@ class LoginAuthMiddleware
22 */ 22 */
23 public function handle(Request $request, Closure $next) 23 public function handle(Request $request, Closure $next)
24 { 24 {
  25 + @file_put_contents(storage_path('logs/lyh_error.log'), var_export(1111, true) . PHP_EOL, FILE_APPEND);
25 $token = $request->header('token'); 26 $token = $request->header('token');
  27 + @file_put_contents(storage_path('logs/lyh_error.log'), var_export($token, true) . PHP_EOL, FILE_APPEND);
26 $info = Cache::get($token); 28 $info = Cache::get($token);
27 if(empty($info) || empty($token)){ 29 if(empty($info) || empty($token)){
28 return response(['code'=>Code::USER_LOGIN_ERROE,'msg'=>'当前用户未登录']); 30 return response(['code'=>Code::USER_LOGIN_ERROE,'msg'=>'当前用户未登录']);