send_self_presence(JID, State) ->
AvatarHash = (State#state.config)#config.vcard_xupdate,
DiscoInfo = make_disco_info(JID, State),
- DiscoHash = mod_caps:compute_disco_hash(DiscoInfo, sha),
+ Extras = iq_disco_info_extras(<<"en">>, State, true),
+ DiscoInfo1 = DiscoInfo#disco_info{xdata = [Extras]},
+ DiscoHash = mod_caps:compute_disco_hash(DiscoInfo1, sha),
Els1 = [#caps{hash = <<"sha-1">>,
node = ejabberd_config:get_uri(),
version = DiscoHash}],
try
true = mod_caps:is_valid_node(Node),
DiscoInfo = make_disco_info(From, StateData),
- Hash = mod_caps:compute_disco_hash(DiscoInfo, sha),
- Node = <<(ejabberd_config:get_uri())/binary, $#, Hash/binary>>,
Extras = iq_disco_info_extras(Lang, StateData, true),
- {result, DiscoInfo#disco_info{node = Node, xdata = [Extras]}}
+ DiscoInfo1 = DiscoInfo#disco_info{xdata = [Extras]},
+ Hash = mod_caps:compute_disco_hash(DiscoInfo1, sha),
+ Node = <<(ejabberd_config:get_uri())/binary, $#, Hash/binary>>,
+ {result, DiscoInfo1#disco_info{node = Node}}
catch _:{badmatch, _} ->
Txt = <<"Invalid node name">>,
{error, xmpp:err_item_not_found(Txt, Lang)}