Fix JavaScript error on the login page

This commit is contained in:
Frédéric Guillot 2024-03-13 21:40:56 -07:00
parent 5948786b15
commit ca919c2ff8

View file

@ -117,8 +117,10 @@ document.addEventListener("DOMContentLoaded", () => {
fixVoiceOverDetailsSummaryBug();
const logoElement = document.querySelector(".logo");
logoElement.addEventListener("click", toggleMainMenu);
logoElement.addEventListener("keydown", toggleMainMenu);
if (logoElement) {
logoElement.addEventListener("click", toggleMainMenu);
logoElement.addEventListener("keydown", toggleMainMenu);
}
onClick(".header nav li", (event) => onClickMainMenuListItem(event));