comparison mod_muc_http_auth/mod_muc_http_auth.lua @ 4319:caaa40f072da

mod_muc_http_auth: `no-authorized` error must be of type `auth`
author JC Brand <jc@opkode.com>
date Wed, 06 Jan 2021 13:48:49 +0100
parents aec8148df26a
children 9606e7a63a69
comparison
equal deleted inserted replaced
4318:3dd7840cb923 4319:caaa40f072da
53 local verb = verbs[stanza.name]; 53 local verb = verbs[stanza.name];
54 if not (response and response.allowed) then 54 if not (response and response.allowed) then
55 -- User is not authorized to join this room 55 -- User is not authorized to join this room
56 err = (response or {}).err or err 56 err = (response or {}).err or err
57 module:log("debug", user_bare_jid .. " is not authorized to " ..verb.. ": " .. room.jid .. " Error: " .. tostring(err)); 57 module:log("debug", user_bare_jid .. " is not authorized to " ..verb.. ": " .. room.jid .. " Error: " .. tostring(err));
58 origin.send(st.error_reply(stanza, "error", "not-authorized", nil, module.host)); 58 origin.send(st.error_reply(stanza, "auth", "not-authorized", nil, module.host));
59 return true; 59 return true;
60 end 60 end
61 61
62 module:log("debug", user_bare_jid .. " is authorized to " .. verb .. ": " .. room.jid); 62 module:log("debug", user_bare_jid .. " is authorized to " .. verb .. ": " .. room.jid);
63 return; 63 return;