mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
Use 'to' field only in the first client stream initialization
This commit is contained in:
parent
155c8bb29a
commit
d63be79df9
@ -291,7 +291,12 @@ wait_for_stream({xmlstreamstart, _Name, Attrs}, StateData) ->
|
||||
DefaultLang = ?MYLANG,
|
||||
case xml:get_attr_s(<<"xmlns:stream">>, Attrs) of
|
||||
?NS_STREAM ->
|
||||
Server = jlib:nameprep(xml:get_attr_s(<<"to">>, Attrs)),
|
||||
Server =
|
||||
case StateData#state.server of
|
||||
undefined ->
|
||||
jlib:nameprep(xml:get_attr_s(<<"to">>, Attrs));
|
||||
S -> S
|
||||
end,
|
||||
case lists:member(Server, ?MYHOSTS) of
|
||||
true ->
|
||||
Lang = case xml:get_attr_s(<<"xml:lang">>, Attrs) of
|
||||
|
Loading…
Reference in New Issue
Block a user