Files
web/scripts/js/logout.js
XhmikosR 3f689d0f55 logout.js: add missing preventDefault call
Without it the target `#` is followed which is not wanted

Signed-off-by: XhmikosR <xhmikosr@gmail.com>
2025-03-08 22:26:31 +02:00

17 lines
546 B
JavaScript

/* Pi-hole: A black hole for Internet advertisements
* (c) 2023 Pi-hole, LLC (https://pi-hole.net)
* Network-wide ad blocking via your own hardware.
*
* This file is copyright under the latest version of the EUPL.
* Please see LICENSE file for your rights under this license. */
/* global utils:false */
document.addEventListener("DOMContentLoaded", () => {
const logoutButton = document.getElementById("logout-button");
logoutButton.addEventListener("click", event => {
event.preventDefault();
utils.doLogout();
});
});