Remove opt_type, as ejabberd expects it to be in ejabberd_options (#284)
This commit is contained in:
parent
f32bb792bc
commit
9d51b80051
|
@ -10,8 +10,6 @@
|
||||||
|
|
||||||
-behaviour(ejabberd_auth).
|
-behaviour(ejabberd_auth).
|
||||||
|
|
||||||
-behaviour(ejabberd_config).
|
|
||||||
|
|
||||||
%% External exports
|
%% External exports
|
||||||
-export([start/1,
|
-export([start/1,
|
||||||
set_password/3,
|
set_password/3,
|
||||||
|
@ -27,7 +25,6 @@
|
||||||
store_type/1,
|
store_type/1,
|
||||||
login/2,
|
login/2,
|
||||||
get_password/3,
|
get_password/3,
|
||||||
opt_type/1,
|
|
||||||
stop/1]).
|
stop/1]).
|
||||||
|
|
||||||
-include("scram.hrl").
|
-include("scram.hrl").
|
||||||
|
@ -37,23 +34,6 @@
|
||||||
%%% API
|
%%% API
|
||||||
%%%----------------------------------------------------------------------
|
%%%----------------------------------------------------------------------
|
||||||
|
|
||||||
opt_type(auth_opts) ->
|
|
||||||
fun(L) ->
|
|
||||||
lists:map(
|
|
||||||
fun({host, V}) when is_binary(V) ->
|
|
||||||
{host, V};
|
|
||||||
({connection_pool_size, V}) when is_integer(V) ->
|
|
||||||
{connection_pool_size, V};
|
|
||||||
({connection_opts, V}) when is_list(V) ->
|
|
||||||
{connection_opts, V};
|
|
||||||
({basic_auth, V}) when is_binary(V) ->
|
|
||||||
{basic_auth, V};
|
|
||||||
({path_prefix, V}) when is_binary(V) ->
|
|
||||||
{path_prefix, V}
|
|
||||||
end, L)
|
|
||||||
end;
|
|
||||||
opt_type(_) -> [auth_opts].
|
|
||||||
|
|
||||||
-spec start(binary()) -> ok.
|
-spec start(binary()) -> ok.
|
||||||
start(Host) ->
|
start(Host) ->
|
||||||
AuthOpts = ejabberd_config:get_option({auth_opts, Host}, fun(V) -> V end),
|
AuthOpts = ejabberd_config:get_option({auth_opts, Host}, fun(V) -> V end),
|
||||||
|
|
Loading…
Reference in New Issue