From e46f436a472a017889f146bc4fcad1d1b2d379ac Mon Sep 17 00:00:00 2001 From: lukebarnard Date: Tue, 6 Feb 2018 11:50:34 +0000 Subject: [PATCH] Prefer context.matrixClient in LeftPanel --- src/components/structures/LeftPanel.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/structures/LeftPanel.js b/src/components/structures/LeftPanel.js index c1222396e1..398862f22e 100644 --- a/src/components/structures/LeftPanel.js +++ b/src/components/structures/LeftPanel.js @@ -24,7 +24,6 @@ import { MatrixClient } from 'matrix-js-sdk'; import { KeyCode } from 'matrix-react-sdk/lib/Keyboard'; import sdk from 'matrix-react-sdk'; import dis from 'matrix-react-sdk/lib/dispatcher'; -import MatrixClientPeg from 'matrix-react-sdk/lib/MatrixClientPeg'; import VectorConferenceHandler from '../../VectorConferenceHandler'; import SettingsStore from "matrix-react-sdk/lib/settings/SettingsStore"; @@ -206,7 +205,7 @@ var LeftPanel = React.createClass({ dis.dispatch(RoomListActions.tagRoom( this.context.matrixClient, - MatrixClientPeg.get().getRoom(roomId), + this.context.matrixClient.getRoom(roomId), prevTag, newTag, oldIndex, newIndex, ), true); @@ -223,7 +222,7 @@ var LeftPanel = React.createClass({ const CallPreview = sdk.getComponent('voip.CallPreview'); let topBox; - if (MatrixClientPeg.get().isGuest()) { + if (this.context.matrixClient.isGuest()) { const LoginBox = sdk.getComponent('structures.LoginBox'); topBox = ; } else {