X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=plugins%2Fadhoc%2Fmod_adhoc.lua;h=1c956021aaf19fddb91ad2f8c40b50d14896c8aa;hb=ea83efae5b3356534f19799f67e97f6f4555adf9;hp=f3e7f52029edcdb1d34efe36365d70d910dd850a;hpb=37105ec863ddbb6fe6885269d816e0a48f82bbf5;p=prosody.git diff --git a/plugins/adhoc/mod_adhoc.lua b/plugins/adhoc/mod_adhoc.lua index f3e7f520..1c956021 100644 --- a/plugins/adhoc/mod_adhoc.lua +++ b/plugins/adhoc/mod_adhoc.lua @@ -34,7 +34,8 @@ module:hook("host-disco-info-node", function (event) reply:tag("feature", { var = "jabber:x:data" }):up(); event.exists = true; else - return origin.send(st.error_reply(stanza, "auth", "forbidden", "This item is not available to you")); + origin.send(st.error_reply(stanza, "auth", "forbidden", "This item is not available to you")); + return true; end elseif node == xmlns_cmd then reply:tag("identity", { name = "Ad-Hoc Commands", @@ -87,7 +88,8 @@ module:hook("iq/host/"..xmlns_cmd..":command", function (event) return true end -- User has permission now execute the command - return adhoc_handle_cmd(commands[node], origin, stanza); + adhoc_handle_cmd(commands[node], origin, stanza); + return true; end end end, 500);