Skip to content

Commit

Permalink
Update import
Browse files Browse the repository at this point in the history
  • Loading branch information
harsh-mn-yral committed Nov 17, 2023
1 parent 307550e commit a2de614
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ export const load: PageLoad = async () => {
}
const data = res.docs[0].data() as UpDownPost

if (data?.ouid && data?.oid) {
throw redirect(307, `/up-down/${data.ouid}@${data.oid}`)
if (data) {
throw redirect(307, `/up-down/${res.docs[0].id}`)
} else {
throw redirect(307, '/up-down/no-videos')
}
Expand Down

0 comments on commit a2de614

Please sign in to comment.