Fix private_get command sending a proper xmlel (#1683)

This commit is contained in:
Badlop 2017-04-20 16:50:08 +02:00
parent 4e86a71ab2
commit ca9d04ba6b
1 changed files with 2 additions and 1 deletions

View File

@ -1363,8 +1363,9 @@ get_last(User, Server) ->
%% <aa xmlns='bb'>Cluth</aa>
private_get(Username, Host, Element, Ns) ->
ElementXml = [{Ns, #xmlel{name = Element, attrs = [{<<"xmlns">>, Ns}]}}],
Els = mod_private:get_data(jid:nodeprep(Username), jid:nameprep(Host),
[Ns, Element]),
[{Ns, ElementXml}]),
binary_to_list(fxml:element_to_binary(xmpp:encode(#private{xml_els = Els}))).
private_set(Username, Host, ElementString) ->