Skip to content

Commit

Permalink
prevent reload on login form submit
Browse files Browse the repository at this point in the history
  • Loading branch information
rottencandy committed Nov 10, 2023
1 parent 542a8c0 commit fac0265
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion webui-src/app/login.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,12 @@ function loginComponent() {
const buttonLogin = () =>
m(
'button[type=submit].submit-btn#loginBtn',
{ onclick: () => verifyLogin(uname, passwd, url) },
{
onclick: (ev) => {
ev.preventDefault();
verifyLogin(uname, passwd, url);
},
},
'Login'
);

Expand Down

0 comments on commit fac0265

Please sign in to comment.