diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html
index 696c202..efcb977 100644
--- a/layouts/partials/footer.html
+++ b/layouts/partials/footer.html
@@ -16,6 +16,7 @@
}
function setMenuToggleListener() {
const menuToggle = document.querySelector('.menu-toggle');
+ if (!menuToggle) return;
body = document.querySelector('body');
menuToggle.addEventListener('click', menuToggleListener);
}