Skip to content

Commit

Permalink
fix(AlEncr): finnaly disabled autologin on encryped
Browse files Browse the repository at this point in the history
  • Loading branch information
Random-user420 committed Sep 25, 2024
1 parent a6f4e9d commit 9dec9d5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions autologin.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ function set_stored_credentials(username, password, enabled, encrypt) {
if (username !== null && username !== undefined && username !== "" && password !== null && password !== undefined && password !== "") {
localStorage.setItem("username", username);
localStorage.setItem("password", password);
localStorage.setItem("encrypt", encrypt);
}
localStorage.setItem("enabled", enabled);
localStorage.setItem("encrypt", encrypt);
}

function get_stored_credentials() {
Expand Down Expand Up @@ -79,9 +79,6 @@ function login() {
if (username_ == null || password_ == null) {
return;
}
if (getEnrcyptEnabled() === "true" || getEnrcyptEnabled() === true) {
return;
}
document.getElementById("UserName").value = username_;
document.getElementById("Password").value = password_;
sleep(300);
Expand Down
2 changes: 1 addition & 1 deletion init.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ window.addEventListener("pageshow", () => {
startInfiniteLoop();
}, 600);
}
if (urlpath === "/" && get_credentials_enabled() === "true") {
if (urlpath === "/" && get_credentials_enabled() === "true" && (getEnrcyptEnabled() != "true" && getEnrcyptEnabled() != true)) {
login();
}

Expand Down

0 comments on commit 9dec9d5

Please sign in to comment.