25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-20 17:27:00 +01:00

Don't use lists:keyfind/3 bcause it was introduced only in recent R13A.

SVN Revision: 2341
This commit is contained in:
Badlop 2009-06-25 18:05:12 +00:00
parent edb5211f5f
commit 523239d5a7

View File

@ -59,8 +59,8 @@ set(_) ->
exit("Loglevel must be an integer").
level_to_integer(Level) ->
case lists:keyfind(Level, 2, ?LOG_LEVELS) of
{Int, Level, _Desc} -> Int;
case lists:keysearch(Level, 2, ?LOG_LEVELS) of
{value, {Int, Level, _Desc}} -> Int;
_ -> erlang:error({no_such_loglevel, Level})
end.