]> BookStack Code Mirror - bookstack/blobdiff - app/Activity/Models/View.php
respective book and chapter structure added.
[bookstack] / app / Activity / Models / View.php
index a6bc2139ee5685053d66ed14b79abe4dfb7c74a8..30ead11935ff38449a0eef3b2bf9cf6905180121 100644 (file)
@@ -41,7 +41,7 @@ class View extends Model
     public static function incrementFor(Viewable $viewable): int
     {
         $user = user();
-        if (is_null($user) || $user->isDefault()) {
+        if ($user->isGuest()) {
             return 0;
         }
 
@@ -54,12 +54,4 @@ class View extends Model
 
         return $view->views;
     }
-
-    /**
-     * Clear all views from the system.
-     */
-    public static function clearAll()
-    {
-        static::query()->truncate();
-    }
 }