Skip to content

Commit

Permalink
If this is null fallback to window
Browse files Browse the repository at this point in the history
  • Loading branch information
ydaniv committed May 3, 2024
1 parent e2665d0 commit 0988eb1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/scrollend.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ if (!supported) {
if (type != 'scroll' && type != 'scrollend')
return;

let scrollport = this;
let scrollport = this || window;
let data = observed.get(scrollport);
if (data === undefined) {
let timeout = 0;
Expand Down

0 comments on commit 0988eb1

Please sign in to comment.