Skip to content

Commit

Permalink
Merge pull request #18094 from Snuffleupagus/rm-unnecessary-signal
Browse files Browse the repository at this point in the history
Remove unnecessary `signal` parameter from `removeEventListener` calls
  • Loading branch information
timvandermeij committed May 15, 2024
2 parents 66c2bf6 + 656963e commit b800268
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions web/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2044,8 +2044,8 @@ const PDFViewerApplication = {
passive: true,
signal,
});
mainContainer.removeEventListener("scrollend", scrollend, { signal });
mainContainer.removeEventListener("blur", scrollend, { signal });
mainContainer.removeEventListener("scrollend", scrollend);
mainContainer.removeEventListener("blur", scrollend);
};
const scroll = () => {
if (this._isCtrlKeyDown) {
Expand All @@ -2059,10 +2059,7 @@ const PDFViewerApplication = {
return;
}

mainContainer.removeEventListener("scroll", scroll, {
passive: true,
signal,
});
mainContainer.removeEventListener("scroll", scroll, { passive: true });
this._isScrolling = true;
mainContainer.addEventListener("scrollend", scrollend, { signal });
mainContainer.addEventListener("blur", scrollend, { signal });
Expand Down

0 comments on commit b800268

Please sign in to comment.