fix: frontend: unhandled exception in case of failed login
Massimo Melina committed
Apr 9, 2022 at 12:18 UTC
6d31334a9cb3239ec222808881d1e3537b152f31
1 file changed
+1
-1
frontend/src/menu.ts
+1
-1
@@ -163,7 +163,7 @@ function LoginButton() {
163
const password = await promptDialog('Password', { type: 'password' })
164
if (!password) return
165
const res = await login(user, password)
166
- if (res.redirect)
166
+ if (res?.redirect)
167
navigate(res.redirect)
168
}
169
})