Clean up /logout command flow and errors (#4918)

Этот коммит содержится в:
Joram Wilander
2016-12-30 13:12:43 -05:00
коммит произвёл Christopher Speller
родитель 28a7a2f200
Коммит 2a91e5e031
4 изменённых файлов: 19 добавлений и 14 удалений

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

@@ -125,6 +125,11 @@ export default class CreatePost extends React.Component {
(data) => {
this.setState({submitting: false});
if (post.message.trim() === '/logout') {
GlobalActions.clientLogout(data.goto_location);
return;
}
if (data.goto_location && data.goto_location.length > 0) {
browserHistory.push(data.goto_location);
}