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

Fix for Erlang R12, that doesn't support: true andalso ok

This commit is contained in:
Badlop 2010-06-15 22:59:53 +02:00
parent 1142cdad1b
commit e27dda3ff1

View File

@ -646,10 +646,14 @@ route_message(From, To, Packet) ->
case ejabberd_auth:is_user_exists(exmpp_jid:prep_node_as_list(To), case ejabberd_auth:is_user_exists(exmpp_jid:prep_node_as_list(To),
exmpp_jid:prep_domain_as_list(To)) of exmpp_jid:prep_domain_as_list(To)) of
true -> true ->
is_privacy_allow(From, To, Packet) andalso case is_privacy_allow(From, To, Packet) of
ejabberd_hooks:run(offline_message_hook, true ->
exmpp_jid:prep_domain(To), ejabberd_hooks:run(offline_message_hook,
[From, To, Packet]); exmpp_jid:prep_domain(To),
[From, To, Packet]);
false ->
ok
end;
_ -> _ ->
Err = exmpp_stanza:reply_with_error( Err = exmpp_stanza:reply_with_error(
Packet, 'service-unaivailable'), Packet, 'service-unaivailable'),