From 101baaf12330a4ccfa711b729e9baad763a03bd3 Mon Sep 17 00:00:00 2001 From: Altay Date: Sat, 16 Dec 2023 14:34:47 +0300 Subject: [PATCH] refactor: remove `description` prop from `show-card` --- app/shows/page.tsx | 7 ++----- components/show-card.stories.tsx | 2 -- components/show-card.tsx | 2 +- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/app/shows/page.tsx b/app/shows/page.tsx index 4049450..68345bd 100644 --- a/app/shows/page.tsx +++ b/app/shows/page.tsx @@ -7,9 +7,7 @@ import { cookies } from 'next/headers'; const fetchAllShows = async () => { const supabase = createSupabaseServerClient(cookies()); - const response = await supabase - .from('show') - .select('id, title, description, images'); + const response = await supabase.from('show').select('id, title, images'); return response; }; @@ -19,7 +17,7 @@ const _fetchMyShows = async () => { const accountId = await getAccountId(); const response = await supabase .from('account_show_relation') - .select('id, show (title, description, images)') + .select('id, show (title, images)') .eq('account', accountId); return response; @@ -51,7 +49,6 @@ export default async function Page() { > {data.map((show) => ( = { render: () => ( = { return ( , 'description' | 'images' | 'title'>; +type Props = Pick, 'images' | 'title'>; function ShowCardImage(props: Pick) { return (