feat: implement QOL features (Stats, Search, Dram of the Day)
This commit is contained in:
@@ -13,7 +13,11 @@ export async function updateBottleStatus(bottleId: string, status: 'sealed' | 'o
|
||||
|
||||
const { error } = await supabase
|
||||
.from('bottles')
|
||||
.update({ status, updated_at: new Date().toISOString() })
|
||||
.update({
|
||||
status,
|
||||
updated_at: new Date().toISOString(),
|
||||
finished_at: status === 'empty' ? new Date().toISOString() : null
|
||||
})
|
||||
.eq('id', bottleId)
|
||||
.eq('user_id', session.user.id);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user