From 17a57eb3e5104e0df010bdee7f34b4ab929b0632 Mon Sep 17 00:00:00 2001 From: Travis Ralston Date: Fri, 5 Apr 2019 09:43:29 -0600 Subject: [PATCH] Bind the onWheel listener directly to props React doesn't seem to care if this is null/undefined. --- src/components/structures/AutoHideScrollbar.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/components/structures/AutoHideScrollbar.js b/src/components/structures/AutoHideScrollbar.js index 4055eb4f9d..3f27f51f18 100644 --- a/src/components/structures/AutoHideScrollbar.js +++ b/src/components/structures/AutoHideScrollbar.js @@ -118,19 +118,13 @@ export default class AutoHideScrollbar extends React.Component { return this.containerRef.scrollTop; } - onWheel = (e) => { - if (this.props.onWheel) { - this.props.onWheel(e); - } - }; - render() { return (
{ this.props.children }