]> BookStack Code Mirror - bookstack/blobdiff - app/Actions/ActivityService.php
Add base64 image support
[bookstack] / app / Actions / ActivityService.php
index b2a35fd2a5115c7ba869a35ddbd34e69287b8e6d..73f827e70e329186d9a8fc8d2ecf6749f919da6c 100644 (file)
@@ -78,7 +78,7 @@ class ActivityService
     public function latest(int $count = 20, int $page = 0): array
     {
         $activityList = $this->permissionService
-            ->filterRestrictedEntityRelations($this->activity, 'activities', 'entity_id', 'entity_type')
+            ->filterRestrictedEntityRelations($this->activity->newQuery(), 'activities', 'entity_id', 'entity_type')
             ->orderBy('created_at', 'desc')
             ->with(['user', 'entity'])
             ->skip($count * $page)
@@ -131,7 +131,7 @@ class ActivityService
     public function userActivity(User $user, int $count = 20, int $page = 0): array
     {
         $activityList = $this->permissionService
-            ->filterRestrictedEntityRelations($this->activity, 'activities', 'entity_id', 'entity_type')
+            ->filterRestrictedEntityRelations($this->activity->newQuery(), 'activities', 'entity_id', 'entity_type')
             ->orderBy('created_at', 'desc')
             ->where('user_id', '=', $user->id)
             ->skip($count * $page)