Skip to content

Commit

Permalink
fix(sign): redirect to login if not logged in
Browse files Browse the repository at this point in the history
  • Loading branch information
flowergardn committed Dec 9, 2023
1 parent 3018732 commit d91fcd5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/pages/c/[id]/sign.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ const CardPage: NextPage<{ id: string }> = ({ id }) => {
});

if (isLoaded && !user) {
location.href = `/c/${id}`;
location.href = `https://accounts.bday.quest/sign-in?redirect_url=${encodeURI(
`https://bday.quest/c/${id}`,
)}`;
}

if (cardLoading) return <></>;
Expand Down

0 comments on commit d91fcd5

Please sign in to comment.