summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2016-11-01 08:34:52 -0400
committerChristopher Speller <crspeller@gmail.com>2016-11-01 08:34:52 -0400
commit6d3b3162b031594568b045943422fcac2b2471d1 (patch)
tree0db4704fdcb23969c2bd914cb4be0ca0bcdaa87d
parent1d4f42acd99d707f114bd77c4085f4324b4a5ee2 (diff)
downloadchat-6d3b3162b031594568b045943422fcac2b2471d1.tar.gz
chat-6d3b3162b031594568b045943422fcac2b2471d1.tar.bz2
chat-6d3b3162b031594568b045943422fcac2b2471d1.zip
Fixes for creating teams (#4387)
-rw-r--r--webapp/components/channel_notifications_modal.jsx2
-rw-r--r--webapp/components/create_team/components/team_url.jsx2
-rw-r--r--webapp/stores/channel_store.jsx1
-rw-r--r--webapp/utils/async_client.jsx2
4 files changed, 5 insertions, 2 deletions
diff --git a/webapp/components/channel_notifications_modal.jsx b/webapp/components/channel_notifications_modal.jsx
index 91563a096..59ec40d84 100644
--- a/webapp/components/channel_notifications_modal.jsx
+++ b/webapp/components/channel_notifications_modal.jsx
@@ -80,7 +80,7 @@ export default class ChannelNotificationsModal extends React.Component {
}
createNotifyLevelSection(serverError) {
// Get glabal user setting for notifications
- const globalNotifyLevel = this.props.currentUser.notify_props.desktop;
+ const globalNotifyLevel = this.props.currentUser.notify_props ? this.props.currentUser.notify_props.desktop : 'all';
let globalNotifyLevelName;
if (globalNotifyLevel === 'all') {
globalNotifyLevelName = (
diff --git a/webapp/components/create_team/components/team_url.jsx b/webapp/components/create_team/components/team_url.jsx
index 222755197..4bea240da 100644
--- a/webapp/components/create_team/components/team_url.jsx
+++ b/webapp/components/create_team/components/team_url.jsx
@@ -27,11 +27,13 @@ export default class TeamUrl extends React.Component {
isLoading: false
};
}
+
submitBack(e) {
e.preventDefault();
this.props.state.wizard = 'display_name';
this.props.updateParent(this.props.state);
}
+
submitNext(e) {
e.preventDefault();
diff --git a/webapp/stores/channel_store.jsx b/webapp/stores/channel_store.jsx
index f0258d02a..3212c1155 100644
--- a/webapp/stores/channel_store.jsx
+++ b/webapp/stores/channel_store.jsx
@@ -400,6 +400,7 @@ ChannelStore.dispatchToken = AppDispatcher.register((payload) => {
ChannelStore.resetCounts(currentId);
}
ChannelStore.setUnreadCountsByMembers(action.members);
+ ChannelStore.emitChange();
break;
case ActionTypes.RECEIVED_MORE_CHANNELS:
ChannelStore.storeMoreChannels(action.channels);
diff --git a/webapp/utils/async_client.jsx b/webapp/utils/async_client.jsx
index 67100ea3f..c23270216 100644
--- a/webapp/utils/async_client.jsx
+++ b/webapp/utils/async_client.jsx
@@ -243,7 +243,7 @@ export function getMoreChannels(force) {
}
export function getChannelStats(channelId = ChannelStore.getCurrentId()) {
- if (isCallInProgress('getChannelStats' + channelId)) {
+ if (isCallInProgress('getChannelStats' + channelId) || channelId == null) {
return;
}