zhuchengjie 2 rokov pred
rodič
commit
768f281c2c

+ 2 - 2
app/Http/Controllers/QuickApp/Book/BookController.php

@@ -142,8 +142,8 @@ class BookController extends BaseController
                 $price = $this->getPrice($book_info);
                 return $this->isBookNeedCharge($bid, $price);
             default:
-                $price = $last_chapter->is_vip ? $this->getPrice($book_info, $last_chapter->size) : 0;
-                return $last_chapter->is_vip ? $this->isChapterNeedCharge($bid, $last_chapter->id, $price) : false;
+                $price = isset($last_chapter->is_vip) ? $this->getPrice($book_info, $last_chapter->size) : 0;
+                return isset($last_chapter->is_vip) ? $this->isChapterNeedCharge($bid, $last_chapter->id, $price) : false;
         }
     }