fix: login fails if a space is added at the end by accident #380
Massimo Melina committed
Oct 17, 2023 at 23:39 UTC
4cb53751f67b4deebaa6b6643821fa6b53fdaf75
1 file changed
+1
-1
frontend/src/login.ts
+1
-1
@@ -103,7 +103,7 @@ export async function loginDialog(navigate: ReturnType<typeof useNavigate>) {
103
104
async function go(ev?: Event) {
105
ev?.stopPropagation()
106
- const usr = usrRef.current?.value
106
+ const usr = usrRef.current?.value.trim()
107
const pwd = pwdRef.current?.value
108
if (going || !usr || !pwd) return
109
going = true