mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
Match ldap_uidattr_format case-insensitively (EJAB-1449)
This commit is contained in:
parent
06e3503976
commit
8d4945aa7f
@ -94,9 +94,13 @@ get_user_part(String, Pattern) ->
|
||||
{'EXIT', _} ->
|
||||
{error, badmatch};
|
||||
Result ->
|
||||
case re:replace(Pattern, "%u", Result, [{return, list}]) of
|
||||
String -> {ok, Result};
|
||||
_ -> {error, badmatch}
|
||||
case string:to_lower(
|
||||
re:replace(Pattern, "%u", Result, [{return, list}])) ==
|
||||
string:to_lower(String) of
|
||||
true ->
|
||||
{ok, Result};
|
||||
false ->
|
||||
{error, badmatch}
|
||||
end
|
||||
end.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user