Merge pull request #2132 from mattermost/no-theme-fix2

RC2 - Fix canceling themes when user has no theme
Этот коммит содержится в:
Christopher Speller
2016-02-10 11:09:38 -05:00
родитель 6225522478 6bcfe4ecad
Коммит 6bfb90ccc5

Просмотреть файл

@@ -7,6 +7,7 @@ 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';
const Modal = ReactBootstrap.Modal;
@@ -224,7 +225,9 @@ class UserSettingsModal extends React.Component {
resetTheme() {
const user = UserStore.getCurrentUser();
if (user.theme_props != null) {
if (user.theme_props == null) {
Utils.applyTheme(Constants.THEMES.default);
} else {
Utils.applyTheme(user.theme_props);
}
}