diff --git a/src/ejabberd_auth_external.erl b/src/ejabberd_auth_external.erl index ecd8552b1..9ae6c9081 100644 --- a/src/ejabberd_auth_external.erl +++ b/src/ejabberd_auth_external.erl @@ -172,7 +172,9 @@ remove_user(User, Server, Password) -> get_cache_option(Host) -> case ejabberd_config:get_option( {extauth_cache, Host}, - fun(I) when is_integer(I), I > 0 -> I end) of + fun(false) -> undefined; + (I) when is_integer(I), I > 0 -> I + end) of undefined -> false; CacheTime -> {true, CacheTime} end.