mod_mix_pam: Fix pushing the wrong value

This commit is contained in:
PapaTutuWawa 2021-02-19 17:01:14 +01:00
parent b22fd12c43
commit 756b2f3625

View File

@ -173,7 +173,7 @@ function handle_client_join(event)
local join_iq = st.iq({ type = "set", from = jid.bare(stanza.attr.from), to = client_join.attr.channel, id = stanza.attr.id, xmlns = "jabber:client" }); local join_iq = st.iq({ type = "set", from = jid.bare(stanza.attr.from), to = client_join.attr.channel, id = stanza.attr.id, xmlns = "jabber:client" });
join_iq:add_child(join); join_iq:add_child(join);
add_state(stanza.attr.id, origin); add_state(stanza.attr.id, jid.resource(from));
module:send(join_iq); module:send(join_iq);
return true; return true;
@ -200,7 +200,7 @@ function handle_client_leave(event)
local leave_iq = st.iq({ type = "set", from = jid.bare(stanza.attr.from), to = client_leave.attr.channel, id = stanza.attr.id }); local leave_iq = st.iq({ type = "set", from = jid.bare(stanza.attr.from), to = client_leave.attr.channel, id = stanza.attr.id });
leave_iq:add_child(leave); leave_iq:add_child(leave);
add_state(stanza.attr.id, origin); add_state(stanza.attr.id, jid.resource(from));
module:send(leave_iq); module:send(leave_iq);
return true; return true;