From 2f67c339a3a06a759fe504a2158113e826369e27 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Mon, 13 Apr 2020 02:46:03 +0200 Subject: mod_component: Reply with a different error when not connected The wait, service-unavailable is overloaded by XEP-0045 to mean that the room has reached the maximum number of users. See #1495. Bouncing errors for components is tricky since there is no way to tell that it comes from the server hosting the component, not from the other end of the component connection. --- plugins/mod_component.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins') diff --git a/plugins/mod_component.lua b/plugins/mod_component.lua index 9ffc496e..2189aceb 100644 --- a/plugins/mod_component.lua +++ b/plugins/mod_component.lua @@ -132,7 +132,7 @@ function module.add_host(module) end module:log("warn", "Component not connected, bouncing error for: %s", stanza:top_tag()); if stanza.attr.type ~= "error" and stanza.attr.type ~= "result" then - event.origin.send(st.error_reply(stanza, "wait", "service-unavailable", "Component unavailable", module.host)); + event.origin.send(st.error_reply(stanza, "wait", "remote-server-timeout", "Component unavailable", module.host)); end end return true; -- cgit v1.2.3