feat: check for password existence
This commit is contained in:
parent
b03df8f0e4
commit
498ecdf68b
7 changed files with 73 additions and 15 deletions
|
@ -0,0 +1,12 @@
|
|||
const id = document.getElementById("public_id");
|
||||
const pwd = document.getElementById("password");
|
||||
const ls = window.localStorage;
|
||||
|
||||
if (id && pwd) {
|
||||
ls.setItem(`ecoffee-pwd:${id.dataset.content}`, pwd.dataset.content);
|
||||
}
|
||||
|
||||
let loc = new URL(window.location.href);
|
||||
loc.search = "";
|
||||
loc.pathname = `/${id.dataset.content}`;
|
||||
window.location = loc;
|
Loading…
Add table
Add a link
Reference in a new issue