瀏覽代碼

Merge branch 'kuaiyingyong' of iqiyoo:zhuishuyun_wap into zhucj

zhuchengjie 2 年之前
父節點
當前提交
6f0f904d46
共有 1 個文件被更改,包括 6 次插入1 次删除
  1. 6 1
      app/Modules/Book/Services/BookService.php

+ 6 - 1
app/Modules/Book/Services/BookService.php

@@ -14,7 +14,12 @@ class BookService
 {
     public static function decodeBidStatic(string $bid)
     {
-        return Hashids::decode($bid)[0];
+        $decodeBid = Hashids::decode($bid);
+        $decodeBid = is_array($decodeBid) ? array_shift($decodeBid) : $decodeBid;
+        if(empty($decodeBid)){
+            myLog("QappBookBidDecodeError")->info("bid : {$bid}, decodeBid : ".var_export($decodeBid,true));
+        }
+        return intval($decodeBid);
     }
 
     /**