25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-22 16:20:52 +01:00

add node attribute to pubsub subscribe event (EJAB-1361)

This commit is contained in:
Christophe Romain 2010-12-07 13:53:58 +01:00
parent a8bf889e79
commit 53cc032251

View File

@ -2320,9 +2320,11 @@ subscribe_node(Host, Node, From, JID, Configuration) ->
SubAttrs = case Subscription of
{subscribed, SubId} ->
[?XMLATTR(<<"subscription">>, subscription_to_string(subscribed)),
?XMLATTR(<<"subid">>, SubId)];
?XMLATTR(<<"subid">>, SubId),
?XMLATTR(<<"node">>, Node)];
Other ->
[?XMLATTR(<<"subscription">>, subscription_to_string(Other))]
[?XMLATTR(<<"subscription">>, subscription_to_string(Other)),
?XMLATTR(<<"node">>, Node)]
end,
Fields =
[ ?XMLATTR(<<"jid">>, JID) | SubAttrs],