Merge pull request #878 from pixelfed/frontend-ui-refactor

Update PublicApiController
pull/904/head
daniel 7 years ago committed by GitHub
commit 199ebc147e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -266,7 +266,21 @@ class PublicApiController extends Controller
->limit($limit)
->get();
} else {
$timeline = Status::whereHas('media')
$timeline = Status::select(
'id',
'uri',
'caption',
'rendered',
'profile_id',
'type',
'in_reply_to_id',
'reblog_of_id',
'is_nsfw',
'scope',
'local',
'created_at',
'updated_at'
)->whereHas('media')
->whereLocal(true)
->whereNull('uri')
->whereNotIn('profile_id', $filtered)
@ -355,7 +369,21 @@ class PublicApiController extends Controller
->limit($limit)
->get();
} else {
$timeline = Status::whereHas('media')
$timeline = Status::select(
'id',
'uri',
'caption',
'rendered',
'profile_id',
'type',
'in_reply_to_id',
'reblog_of_id',
'is_nsfw',
'scope',
'local',
'created_at',
'updated_at'
)->whereHas('media')
->whereLocal(true)
->whereNull('uri')
->whereIn('profile_id', $following)

Loading…
Cancel
Save