Skip to content
This repository was archived by the owner on Jun 7, 2023. It is now read-only.

Commit 03db16c

Browse files
committed
Fix: protect against missnig sticky wrapper
1 parent ac29e60 commit 03db16c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

runestone/common/js/pretext.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,8 @@ function setupPTXEvents() {
2727
window.addEventListener("load", function () {
2828
console.log("setting up pretext");
2929
setupPTXEvents();
30-
document.getElementById("primary-navbar-sticky-wrapper").style.overflow="visible"
30+
let wrap = document.getElementById("primary-navbar-sticky-wrapper");
31+
if (wrap) {
32+
wrap.style.overflow="visible";
33+
}
3134
});

0 commit comments

Comments
 (0)