Skip to content

Commit

Permalink
username null check
Browse files Browse the repository at this point in the history
  • Loading branch information
peintnermax committed Dec 27, 2024
1 parent 4ff9b44 commit e0c1626
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/login/src/components/username-form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ export function UsernameForm({
setLoading(false);
});

if (res?.redirect) {
if (res && "redirect" in res && res.redirect) {
return router.push(res.redirect);
}

if (res?.error) {
if (res && "error" in res && res.error) {
setError(res.error);
return;
}
Expand Down

0 comments on commit e0c1626

Please sign in to comment.