[FIX] mail: client action: crash on channel unsubscribe
After unsubscribing from a channel, the client action switches to inbox. Method set_channel() takes as argument the channel to switch to, not its id.
This commit is contained in:
@@ -462,7 +462,7 @@ var ChatAction = Widget.extend(ControlPanelMixin, {
|
||||
var self = this;
|
||||
chat_manager
|
||||
.unsubscribe(this.channel)
|
||||
.then(this.set_channel.bind(this, "channel_inbox"))
|
||||
.then(this.set_channel.bind(this, chat_manager.get_channel("channel_inbox")))
|
||||
.then(this.render_sidebar.bind(this))
|
||||
.then(function () {
|
||||
var msg = _.str.sprintf(_t('You unsubscribed from <b>%s</b>.'), self.channel.name);
|
||||
|
||||
Reference in New Issue
Block a user