Skip to content

Commit

Permalink
Explicitly require published status to show in listing (#139)
Browse files Browse the repository at this point in the history
  • Loading branch information
phazonoverload committed Mar 6, 2024
1 parent be7ddfe commit 00ffe97
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pages/tv/live/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,11 @@ const directusUrl = process.env.DIRECTUS_TV_URL || tvUrl;
const directus = createDirectus(directusUrl).with(rest());
const globals = await directus.request(readSingleton('globals'));
let events = await directus.request(readItems('events', { sort: ['date_start'] }));
let events = await directus.request(
readItems('events', { sort: ['date_start'], filter: { status: { _eq: 'published' } } }),
);
events = events.map((event) => ({ ...event, published: event.date_start }));
definePageMeta({
Expand Down

0 comments on commit 00ffe97

Please sign in to comment.