New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug 1503101: Fix hash link on pages without TOC #5057

merged 1 commit into from Oct 30, 2018


None yet
2 participants

urty5656 commented Oct 30, 2018

Bugzilla 1503101

This PR changes TOC existence check from toc !== undefined to truthy check, as document.getElementById() returns null.

Example of a page without TOC


This change works for me on the identified page. Thanks for the clear PR, @urty5656!

@jwhitlock jwhitlock merged commit 6472eed into mozilla:master Oct 30, 2018

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
security/snyk - package.json (mdn) No new, high severity issues
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment