Commit 8e704f1
TechStack Global
fix: guard getElementById('year') against null to prevent script crash on pages missing the span
Pages like amazon-stack.html use a static copyright string without
the #year span. The TypeError crashed script.js before the toggle
event listener was attached, breaking the hamburger on all such pages.
Added a null guard: only 1 line changed in script.js.1 parent 8ef55b0 commit 8e704f1
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
0 commit comments