From edf0a35392abbdc91100a4ea8ba1b37daa0b1be0 Mon Sep 17 00:00:00 2001 From: damencho Date: Wed, 12 Mar 2025 11:12:51 -0500 Subject: [PATCH] fix: Drops not needed binds. --- .../filmstrip/components/web/ThumbnailWrapper.tsx | 14 -------------- .../settings/components/web/NotificationsTab.tsx | 4 +--- 2 files changed, 1 insertion(+), 17 deletions(-) diff --git a/react/features/filmstrip/components/web/ThumbnailWrapper.tsx b/react/features/filmstrip/components/web/ThumbnailWrapper.tsx index 320198c068..136477f71e 100644 --- a/react/features/filmstrip/components/web/ThumbnailWrapper.tsx +++ b/react/features/filmstrip/components/web/ThumbnailWrapper.tsx @@ -1,6 +1,5 @@ import React, { Component } from 'react'; import { connect } from 'react-redux'; -import { shouldComponentUpdate } from 'react-window'; import { IReduxState } from '../../../app/types'; import { getLocalParticipant } from '../../../base/participants/functions'; @@ -74,19 +73,6 @@ interface IProps { * to the Thumbnail Component's props. */ class ThumbnailWrapper extends Component { - shouldComponentUpdate: (p: any, s: any) => boolean; - - /** - * Creates new ThumbnailWrapper instance. - * - * @param {IProps} props - The props of the component. - */ - constructor(props: IProps) { - super(props); - - this.shouldComponentUpdate = shouldComponentUpdate.bind(this); - } - /** * Implements React's {@link Component#render()}. * diff --git a/react/features/settings/components/web/NotificationsTab.tsx b/react/features/settings/components/web/NotificationsTab.tsx index 5397cfb406..a4b829035f 100644 --- a/react/features/settings/components/web/NotificationsTab.tsx +++ b/react/features/settings/components/web/NotificationsTab.tsx @@ -133,8 +133,6 @@ class NotificationsTab extends AbstractDialogTab { constructor(props: IProps) { super(props); - // Bind event handlers so they are only bound once for every instance. - this._onChange = this._onChange.bind(this); this._onEnabledNotificationsChanged = this._onEnabledNotificationsChanged.bind(this); } @@ -145,7 +143,7 @@ class NotificationsTab extends AbstractDialogTab { * * @returns {void} */ - _onChange({ target }: React.ChangeEvent) { + override _onChange({ target }: React.ChangeEvent) { super._onChange({ [target.name]: target.checked }); }