mirror of
https://github.com/discourse/discourse.git
synced 2025-05-29 00:00:46 +08:00
FIX: no event when threading is disabled (#21439)
Every replies creates a thread, even when threading is disabled. This is how we ensure we can go back and forth. However, a message bus event should only be published when threading is enabled, otherwise frontend will attempt to display a thread which is not possible when disabled. This fixes a silent background 404 when doing a reply in a direct message channel or a non threading enabled category channel.
This commit is contained in:
@ -388,6 +388,7 @@ RSpec.describe Chat::ChatController do
|
||||
context "when sending a message in a staged thread" do
|
||||
it "creates the thread and publishes with the staged id" do
|
||||
sign_in(user)
|
||||
chat_channel.update!(threading_enabled: true)
|
||||
|
||||
messages =
|
||||
MessageBus.track_publish do
|
||||
|
Reference in New Issue
Block a user