Skip to content

Commit

Permalink
fix(frontend): External login was buggy
Browse files Browse the repository at this point in the history
  • Loading branch information
Brayan-724 committed Sep 15, 2024
1 parent a98dd12 commit 54e0218
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions frontend/src/routes/form/[slug]/+page.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@ export async function load(
};
} else if (session_res.status === 403) {
return error(session_res.status, "Already answered");
} else if (session_res.status === 401) {
// External Code is expired
cookies.delete("external-code", { path: "/" });
return redirect(301, `/form/${params.slug}`);
} else if (!session.success) {
return error(session_res.status, session.errors[0]);
}
Expand Down

0 comments on commit 54e0218

Please sign in to comment.