mirror of
https://code.castopod.org/adaures/castopod
synced 2025-06-06 18:31:05 +00:00
fix(home): update where clause when getting all podcasts to prevent draft podcasts from showing up
This commit is contained in:
parent
11aa3586a0
commit
7a1eea58d3
@ -185,11 +185,13 @@ class PodcastModel extends Model
|
|||||||
$fediverseTablePrefix . 'posts.actor_id = podcasts.actor_id',
|
$fediverseTablePrefix . 'posts.actor_id = podcasts.actor_id',
|
||||||
'left'
|
'left'
|
||||||
)
|
)
|
||||||
|
->groupStart()
|
||||||
->where(
|
->where(
|
||||||
'`' . $fediverseTablePrefix . 'posts`.`published_at` <= UTC_TIMESTAMP()',
|
'`' . $fediverseTablePrefix . 'posts`.`published_at` <= UTC_TIMESTAMP()',
|
||||||
null,
|
null,
|
||||||
false
|
false
|
||||||
)->orWhere($fediverseTablePrefix . 'posts.published_at', null)
|
)->orWhere($fediverseTablePrefix . 'posts.published_at', null)
|
||||||
|
->groupEnd()
|
||||||
->groupBy('podcasts.actor_id')
|
->groupBy('podcasts.actor_id')
|
||||||
->orderBy('max_published_at', 'DESC');
|
->orderBy('max_published_at', 'DESC');
|
||||||
} elseif ($orderBy === 'created_desc') {
|
} elseif ($orderBy === 'created_desc') {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user