From 05f7a3b4d1291be463ed08c9022f13f1d355e9c1 Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 7 Oct 2015 18:44:32 +0100 Subject: [PATCH] Remove now redundant displayname stuff from UserSettings now it's in ChangeDisplayName --- src/controllers/organisms/UserSettings.js | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/controllers/organisms/UserSettings.js b/src/controllers/organisms/UserSettings.js index 60d643c22b..d7bb8d391a 100644 --- a/src/controllers/organisms/UserSettings.js +++ b/src/controllers/organisms/UserSettings.js @@ -26,7 +26,6 @@ module.exports = { getInitialState: function() { return { - displayName: null, avatarUrl: null, threePids: [], clientVersion: version, @@ -34,16 +33,6 @@ module.exports = { }; }, - changeDisplayname: function(new_displayname) { - if (this.state.displayName == new_displayname) return; - - var self = this; - return MatrixClientPeg.get().setDisplayName(new_displayname).then( - function() { self.setState({displayName: new_displayname}); }, - function(err) { console.err(err); } - ); - }, - componentWillMount: function() { var self = this; var cli = MatrixClientPeg.get(); @@ -54,7 +43,6 @@ module.exports = { q.all([profile_d, threepid_d]).then( function(resps) { self.setState({ - displayName: resps[0].displayname, avatarUrl: resps[0].avatar_url, threepids: resps[1].threepids, phase: self.Phases.Display,