25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-24 16:23:40 +01:00

Match all possible values in mod_privilege checks, or we get crashes

This commit is contained in:
Paweł Chmielowski 2018-01-30 13:10:22 +01:00
parent 53870c854e
commit bb58307190

View File

@ -98,7 +98,7 @@ process_message(#message{from = #jid{luser = <<"">>, lresource = <<"">>} = From,
case proplists:get_value(message, Access, none) of
outgoing ->
forward_message(Msg);
none ->
_ ->
Txt = <<"Insufficient privilege">>,
Err = xmpp:err_forbidden(Txt, Lang),
ejabberd_router:route_error(Msg, Err)
@ -172,7 +172,7 @@ process_presence_in({#presence{
true ->
ok
end;
none ->
_ ->
ok
end
end, dict:to_list(Permissions)),