From fa53e34e4513f743b7f525d5eeccca74b7930922 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Thu, 10 Jan 2019 12:25:25 -0700 Subject: [PATCH] Update PublicApiController --- app/Http/Controllers/PublicApiController.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/Http/Controllers/PublicApiController.php b/app/Http/Controllers/PublicApiController.php index 51fe32ee..b38bedfc 100644 --- a/app/Http/Controllers/PublicApiController.php +++ b/app/Http/Controllers/PublicApiController.php @@ -233,6 +233,8 @@ class PublicApiController extends Controller $dir = $min ? '>' : '<'; $id = $min ?? $max; $timeline = Status::whereHas('media') + ->whereLocal(true) + ->whereNull('uri') ->where('id', $dir, $id) ->whereNotIn('profile_id', $filtered) ->whereNull('in_reply_to_id') @@ -244,6 +246,8 @@ class PublicApiController extends Controller ->get(); } else { $timeline = Status::whereHas('media') + ->whereLocal(true) + ->whereNull('uri') ->whereNotIn('profile_id', $filtered) ->whereNull('in_reply_to_id') ->whereNull('reblog_of_id') @@ -295,6 +299,8 @@ class PublicApiController extends Controller $dir = $min ? '>' : '<'; $id = $min ?? $max; $timeline = Status::whereHas('media') + ->whereLocal(true) + ->whereNull('uri') ->where('id', $dir, $id) ->whereIn('profile_id', $following) ->whereNotIn('profile_id', $filtered) @@ -307,6 +313,8 @@ class PublicApiController extends Controller ->get(); } else { $timeline = Status::whereHas('media') + ->whereLocal(true) + ->whereNull('uri') ->whereIn('profile_id', $following) ->whereNotIn('profile_id', $filtered) ->whereNull('in_reply_to_id')