From 86219b57fc56600d4c87100b1dd807e62b250e3e Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Wed, 21 Jul 2021 01:03:43 -0600 Subject: [PATCH] Update PublicApiController, filter out text replies on home timeline --- app/Http/Controllers/PublicApiController.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/Http/Controllers/PublicApiController.php b/app/Http/Controllers/PublicApiController.php index 4557c0cb0..d7c960ba3 100644 --- a/app/Http/Controllers/PublicApiController.php +++ b/app/Http/Controllers/PublicApiController.php @@ -430,6 +430,7 @@ class PublicApiController extends Controller ->where('id', $dir, $id) ->whereIn('profile_id', $following) ->whereNotIn('profile_id', $filtered) + ->whereNull('in_reply_to_id') ->whereIn('visibility',['public', 'unlisted', 'private']) ->orderBy('created_at', 'desc') ->limit($limit) @@ -459,6 +460,7 @@ class PublicApiController extends Controller ->with('profile', 'hashtags', 'mentions') ->whereIn('profile_id', $following) ->whereNotIn('profile_id', $filtered) + ->whereNull('in_reply_to_id') ->whereIn('visibility',['public', 'unlisted', 'private']) ->orderBy('created_at', 'desc') ->simplePaginate($limit);