lh 1 月之前
父節點
當前提交
4b72f4f330
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      app/Http/Middleware/CheckSign.php

+ 4 - 1
app/Http/Middleware/CheckSign.php

@@ -25,7 +25,10 @@ class CheckSign
         $param_sign = $request->header('sign', '');
         $param_sign = $request->header('sign', '');
         $nonce = $request->header('nonce', '');
         $nonce = $request->header('nonce', '');
         $timestamp = $request->header('timestamp', '');
         $timestamp = $request->header('timestamp', '');
-        if (!$token) Utils::throwError(ErrorConst::NOT_LOGIN);
+        if (!$token) {
+            $token = getProp($params, 'd_token');
+            if (!$token) Utils::throwError(ErrorConst::NOT_LOGIN);
+        }
 
 
         $referer_url = $request->input('_url', '');
         $referer_url = $request->input('_url', '');
         // 先验签(非本地模式需要验签)
         // 先验签(非本地模式需要验签)