X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/83d77d516665c41ca445a93119dfd97311bfb498..refs/pull/2522/head:/app/Actions/ViewService.php diff --git a/app/Actions/ViewService.php b/app/Actions/ViewService.php index ec57cdb76..51a60d96e 100644 --- a/app/Actions/ViewService.php +++ b/app/Actions/ViewService.php @@ -74,7 +74,12 @@ class ViewService $query->whereIn('viewable_type', $this->entityProvider->getMorphClasses($filterModels)); } - return $query->with('viewable')->skip($skipCount)->take($count)->get()->pluck('viewable'); + return $query->with('viewable') + ->skip($skipCount) + ->take($count) + ->get() + ->pluck('viewable') + ->filter(); } /**