A platform for community discussion. Free, open, simple.
FIX: prevents back history loop (#22001)
Joffrey JAFFEUX65d61b87c136
diff --git a/plugins/chat/assets/javascripts/discourse/routes/chat-index.js b/plugins/chat/assets/javascripts/discourse/routes/chat-index.jsindex e5d2fcf802e..09c62b06e30 100644--- a/plugins/chat/assets/javascripts/discourse/routes/chat-index.js+++ b/plugins/chat/assets/javascripts/discourse/routes/chat-index.js@@ -16,10 +16,10 @@ export default class ChatIndexRoute extends DiscourseRoute {const id = this.chat.getIdealFirstChannelId();if (id) {return this.chatChannelsManager.find(id).then((c) => {- return this.router.transitionTo("chat.channel", ...c.routeModels);+ return this.router.replaceWith("chat.channel", ...c.routeModels);});} else {- return this.router.transitionTo("chat.browse");+ return this.router.replaceWith("chat.browse");}}