aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_external_services.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-03-23 15:29:01 +0100
committerKim Alvefur <zash@zash.se>2022-03-23 15:29:01 +0100
commite950ca77ebd29994699c944ba6758bde441118cf (patch)
tree534e2039bcc7b53c2763d7cdd6f16b34e22c11ca /plugins/mod_external_services.lua
parentea9ea679110d161e12d7be441258307a461f2150 (diff)
downloadprosody-e950ca77ebd29994699c944ba6758bde441118cf.tar.gz
prosody-e950ca77ebd29994699c944ba6758bde441118cf.zip
mod_external_services: Move error message to correct place (fix #1725)
This message was misplaced in c4599a7c534c when the @type and @host check was introduced.
Diffstat (limited to 'plugins/mod_external_services.lua')
-rw-r--r--plugins/mod_external_services.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/mod_external_services.lua b/plugins/mod_external_services.lua
index 6daa45c7..ae418fd8 100644
--- a/plugins/mod_external_services.lua
+++ b/plugins/mod_external_services.lua
@@ -192,7 +192,7 @@ local function handle_credentials(event)
local action = stanza.tags[1];
if origin.type ~= "c2s" then
- origin.send(st.error_reply(stanza, "auth", "forbidden", "The 'port' and 'type' attributes are required."));
+ origin.send(st.error_reply(stanza, "auth", "forbidden"));
return true;
end
@@ -204,7 +204,7 @@ local function handle_credentials(event)
local requested_credentials = set.new();
for service in action:childtags("service") do
if not service.attr.type or not service.attr.host then
- origin.send(st.error_reply(stanza, "modify", "bad-request"));
+ origin.send(st.error_reply(stanza, "modify", "bad-request", "The 'port' and 'type' attributes are required."));
return true;
end