diff --git a/app/UserFilter.php b/app/UserFilter.php index ab5fe321..50cd5887 100644 --- a/app/UserFilter.php +++ b/app/UserFilter.php @@ -12,4 +12,21 @@ class UserFilter extends Model 'filterable_type', 'filter_type', ]; + + public function mutedUserIds($profile_id) + { + return $this->whereUserId($profile_id) + ->whereFilterableType('App\Profile') + ->whereFilterType('mute') + ->pluck('filterable_id'); + } + + + public function blockedUserIds($profile_id) + { + return $this->whereUserId($profile_id) + ->whereFilterableType('App\Profile') + ->whereFilterType('block') + ->pluck('filterable_id'); + } }