summaryrefslogtreecommitdiffstats
path: root/webapp/components/user_settings/user_settings_modal.jsx
diff options
context:
space:
mode:
authorCorey Hulen <corey@hulen.com>2016-03-24 21:45:23 -0700
committerCorey Hulen <corey@hulen.com>2016-03-24 21:45:23 -0700
commitfb9adbfe5bad035895e21c8205fb99194e203075 (patch)
tree0cc021570d083f81a50a0183012ce39d9053abde /webapp/components/user_settings/user_settings_modal.jsx
parent1147c7ff298d3aabee5f422b454dc65ebbcc3751 (diff)
parente02921f344aece80b90d37986f393326e5f7f98a (diff)
downloadchat-fb9adbfe5bad035895e21c8205fb99194e203075.tar.gz
chat-fb9adbfe5bad035895e21c8205fb99194e203075.tar.bz2
chat-fb9adbfe5bad035895e21c8205fb99194e203075.zip
Merge pull request #2534 from hmhealey/plt2184
PLT-2184 Moved theme reset code to componentWillUnmount
Diffstat (limited to 'webapp/components/user_settings/user_settings_modal.jsx')
-rw-r--r--webapp/components/user_settings/user_settings_modal.jsx14
1 files changed, 0 insertions, 14 deletions
diff --git a/webapp/components/user_settings/user_settings_modal.jsx b/webapp/components/user_settings/user_settings_modal.jsx
index d1c1f0fe2..b71547baf 100644
--- a/webapp/components/user_settings/user_settings_modal.jsx
+++ b/webapp/components/user_settings/user_settings_modal.jsx
@@ -9,7 +9,6 @@ import SettingsSidebar from '../settings_sidebar.jsx';
import UserStore from 'stores/user_store.jsx';
import * as Utils from 'utils/utils.jsx';
-import Constants from 'utils/constants.jsx';
import {Modal} from 'react-bootstrap';
@@ -113,7 +112,6 @@ class UserSettingsModal extends React.Component {
return;
}
- this.resetTheme();
this.deactivateTab();
this.props.onModalDismissed();
return;
@@ -220,22 +218,10 @@ class UserSettingsModal extends React.Component {
if (!skipConfirm && this.requireConfirm) {
this.showConfirmModal(() => this.updateSection(section, true));
} else {
- if (this.state.active_section === 'theme' && section !== 'theme') {
- this.resetTheme();
- }
this.setState({active_section: section});
}
}
- resetTheme() {
- const user = UserStore.getCurrentUser();
- if (user.theme_props == null) {
- Utils.applyTheme(Constants.THEMES.default);
- } else {
- Utils.applyTheme(user.theme_props);
- }
- }
-
render() {
const {formatMessage} = this.props.intl;
if (this.state.currentUser == null) {