Skip to content
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

Missing null check for this.boundaryElement in 'reachedUpperEdge' #54

Closed
ramtennae opened this issue Oct 28, 2019 · 1 comment
Closed
Labels
duplicate This issue or pull request already exists.

Comments

@ramtennae
Copy link

Need to check that this.boundaryElement exists before attempting to access property this.boundaryElement.offsetTop to prevent Cannot read property 'offsetTop' of undefined error.

const reachedUpperEdge = window.pageYOffset < (this.boundaryElement.offsetTop - marginTop);

@ramtennae
Copy link
Author

Closing as duplicate of issue #53 .

@ghost ghost added the duplicate This issue or pull request already exists. label Nov 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists.
Projects
None yet
Development

No branches or pull requests

1 participant