mod_mix: Fix some small errors

This commit is contained in:
PapaTutuWawa 2021-06-03 23:07:41 +02:00
parent 7d90d14fe5
commit e9c31280a6
2 changed files with 2 additions and 4 deletions

View File

@ -110,7 +110,7 @@ function Channel:get_broadcaster()
end
for jid in pairs(jids) do
module:log("debug", "Sending notification to %s from %s for node %s", jid, user_bare, node);
module:log("debug", "Sending notification to %s for node %s", jid, node);
message.attr.to = jid;
module:send(message);
end

View File

@ -388,7 +388,7 @@ module:hook("iq-set/bare/"..namespaces.mix_core..":join", function(event)
-- Prevent the user from joining multiple times
local participant = channel:find_participant(from);
if participant then
module:send(st.error_reply(stanza, "cancel", "bad-request", "User already joined"));
module:send(st.error_reply(stanza, "cancel", "conflict", "User already joined"));
return true;
end
@ -418,7 +418,6 @@ module:hook("iq-set/bare/"..namespaces.mix_core..":join", function(event)
local nodes = {};
local has_subscribed_once = false;
local first_error = nil;
local owner_or_admin = channel:is_admin(from) or channel:is_owner(from);
for subscribe in join:childtags("subscribe") do
-- May the user subscribe to the node?
module:log("debug", "Subscribing user to node %s", subscribe.attr.node);
@ -467,7 +466,6 @@ module:hook("iq-set/bare/"..namespaces.mix_core..":join", function(event)
-- We do not reuse nick_tag as it might be nil
reply:tag("nick"):text(nick):up();
reply:add_child(anon.form:form(config, "result"));
origin.send(reply);
return true
end);