Skip to content

Commit

Permalink
fix(esl-scrollbar): fix event subscriber leak
Browse files Browse the repository at this point in the history
  • Loading branch information
ala-n committed Dec 22, 2021
1 parent 76c363e commit abaf22a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modules/esl-scrollbar/core/esl-scrollbar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -331,11 +331,11 @@ export class ESLScrollbar extends ESLBaseElement {
// Unbind drag listeners
if (EventUtils.isMouseEvent(event)) {
window.removeEventListener('mousemove', this._onPointerMove);
window.removeEventListener('mouseup', this._onPointerMove);
window.removeEventListener('mouseup', this._onPointerUp);
}
if (EventUtils.isTouchEvent(event)) {
window.removeEventListener('touchmove', this._onPointerMove);
window.removeEventListener('touchend', this._onPointerMove);
window.removeEventListener('touchend', this._onPointerUp);
}
}

Expand Down

0 comments on commit abaf22a

Please sign in to comment.