Merge pull request #204 from nickago/MM-1519

MM-1519 Even on error, submission stops, updated to relect that
Этот коммит содержится в:
Joram Wilander
2015-07-20 12:17:48 -04:00
родитель 1c06c3fa09 af56bed1a3
Коммит 6a229964c7

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

@@ -43,7 +43,7 @@ module.exports = React.createClass({
client.createPost(post, ChannelStore.getCurrent(),
function(data) {
this.setState({ messageText: '', submitting: false, post_error: null });
this.setState({ messageText: '', submitting: false, post_error: null, server_error: null });
this.clearPreviews();
AsyncClient.getPosts(true, this.props.channelId);
@@ -57,6 +57,7 @@ module.exports = React.createClass({
function(err) {
var state = {};
state.server_error = err.message;
state.submitting = false;
if (err.message === "Invalid RootId parameter") {
if ($('#post_deleted').length > 0) $('#post_deleted').modal('show');