mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-26 16:23:16 +00:00
Update PublicApiController
This commit is contained in:
parent
0bb665460a
commit
e3c425e222
1 changed files with 4 additions and 2 deletions
|
@ -457,10 +457,11 @@ class PublicApiController extends Controller
|
||||||
)->where('id', $dir, $id)
|
)->where('id', $dir, $id)
|
||||||
->whereIn('type', ['photo', 'photo:album', 'video', 'video:album'])
|
->whereIn('type', ['photo', 'photo:album', 'video', 'video:album'])
|
||||||
->whereNotIn('profile_id', $filtered)
|
->whereNotIn('profile_id', $filtered)
|
||||||
|
->whereNotNull('uri')
|
||||||
->whereNull('in_reply_to_id')
|
->whereNull('in_reply_to_id')
|
||||||
->whereNull('reblog_of_id')
|
->whereNull('reblog_of_id')
|
||||||
->whereVisibility('public')
|
->whereVisibility('public')
|
||||||
->orderBy('created_at', 'desc')
|
->latest()
|
||||||
->limit($limit)
|
->limit($limit)
|
||||||
->get();
|
->get();
|
||||||
} else {
|
} else {
|
||||||
|
@ -484,8 +485,9 @@ class PublicApiController extends Controller
|
||||||
->whereNotIn('profile_id', $filtered)
|
->whereNotIn('profile_id', $filtered)
|
||||||
->whereNull('in_reply_to_id')
|
->whereNull('in_reply_to_id')
|
||||||
->whereNull('reblog_of_id')
|
->whereNull('reblog_of_id')
|
||||||
|
->whereNotNull('uri')
|
||||||
->whereVisibility('public')
|
->whereVisibility('public')
|
||||||
->orderBy('created_at', 'desc')
|
->latest()
|
||||||
->simplePaginate($limit);
|
->simplePaginate($limit);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue