Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #1031 from matrix-org/luke/fix-deferred-start-chat…
Browse files Browse the repository at this point in the history
…-settings

Keep deferred actions for view_user_settings and view_create_chat
  • Loading branch information
dbkr authored Jun 5, 2017
2 parents cdd8cc4 + 3195b9f commit d8e3423
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/components/structures/MatrixChat.js
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,12 @@ module.exports = React.createClass({
break;
case 'view_user_settings':
if (MatrixClientPeg.get().isGuest()) {
dis.dispatch({
action: 'do_after_sync_prepared',
deferred_action: {
action: 'view_user_settings',
},
});
dis.dispatch({action: 'view_set_mxid'});
break;
}
Expand Down Expand Up @@ -703,7 +709,13 @@ module.exports = React.createClass({

_createChat: function() {
if (MatrixClientPeg.get().isGuest()) {
this._setMxId();
dis.dispatch({
action: 'do_after_sync_prepared',
deferred_action: {
action: 'view_create_chat',
},
});
dis.dispatch({action: 'view_set_mxid'});
return;
}
const ChatInviteDialog = sdk.getComponent("dialogs.ChatInviteDialog");
Expand Down

0 comments on commit d8e3423

Please sign in to comment.