Revert "mod_mam: Keep 'to' attribute for MUC MAM messages"

This reverts commit 0e330da2a6.  XEP-0313
says: "When sending out the archives to a requesting client, the 'to' of
the forwarded stanza MUST be empty".
This commit is contained in:
Holger Weiss 2015-12-22 13:20:23 +01:00
parent cfe0aea219
commit 8cf0d31ee9
1 changed files with 2 additions and 1 deletions

View File

@ -794,7 +794,8 @@ maybe_update_from_to(#xmlel{children = Els} = Pkt, JidRequestor,
[]
end,
Pkt1 = Pkt#xmlel{children = Items ++ Els},
Pkt2 = jlib:replace_from(jid:replace_resource(JidRequestor, Nick), Pkt1).
Pkt2 = jlib:replace_from(jid:replace_resource(JidRequestor, Nick), Pkt1),
jlib:remove_attr(<<"to">>, Pkt2).
is_bare_copy(#jid{luser = U, lserver = S, lresource = R}, To) ->
PrioRes = ejabberd_sm:get_user_present_resources(U, S),