diff --git a/apps/login/src/components/session-item.tsx b/apps/login/src/components/session-item.tsx index 449f7dc955..c3c28a03fd 100644 --- a/apps/login/src/components/session-item.tsx +++ b/apps/login/src/components/session-item.tsx @@ -88,11 +88,11 @@ export function SessionItem({ 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; }