mirror of
https://github.com/processone/ejabberd
synced 2025-10-03 09:49:18 +02:00
Remove some options keyword expansion, as they are now predefined
This commit is contained in:
parent
998690f58c
commit
c8abff33c1
3 changed files with 5 additions and 22 deletions
|
@ -546,14 +546,10 @@ sip_uri() ->
|
|||
-spec host() -> yconf:validator(binary()).
|
||||
host() ->
|
||||
fun(Domain) ->
|
||||
Host = ejabberd_config:get_myname(),
|
||||
Hosts = ejabberd_config:get_option(hosts),
|
||||
Domain1 = (binary())(Domain),
|
||||
Domain2 = misc:expand_keyword(<<"@HOST@">>, Domain1, Host),
|
||||
Domain3 = (domain())(Domain2),
|
||||
case lists:member(Domain3, Hosts) of
|
||||
true -> fail({route_conflict, Domain3});
|
||||
false -> Domain3
|
||||
case lists:member(Domain, Hosts) of
|
||||
true -> fail({route_conflict, Domain});
|
||||
false -> Domain
|
||||
end
|
||||
end.
|
||||
|
||||
|
|
|
@ -932,12 +932,7 @@ listen_opt_type(default_host) ->
|
|||
listen_opt_type(custom_headers) ->
|
||||
econf:map(
|
||||
econf:binary(),
|
||||
econf:and_then(
|
||||
econf:binary(),
|
||||
fun(V) ->
|
||||
misc:expand_keyword(<<"@VERSION@">>, V,
|
||||
ejabberd_option:version())
|
||||
end)).
|
||||
econf:binary()).
|
||||
|
||||
listen_options() ->
|
||||
[{ciphers, undefined},
|
||||
|
|
|
@ -112,14 +112,7 @@ opt_type(cache_missed) ->
|
|||
opt_type(cache_size) ->
|
||||
econf:pos_int(infinity);
|
||||
opt_type(captcha_cmd) ->
|
||||
econf:and_then(
|
||||
econf:binary(),
|
||||
fun(V) ->
|
||||
V2 = misc:expand_keyword(<<"@SEMVER@">>, V,
|
||||
ejabberd_option:version()),
|
||||
misc:expand_keyword(<<"@VERSION@">>, V2,
|
||||
misc:semver_to_xxyy(ejabberd_option:version()))
|
||||
end);
|
||||
econf:binary();
|
||||
opt_type(captcha_host) ->
|
||||
econf:binary();
|
||||
opt_type(captcha_limit) ->
|
||||
|
@ -493,7 +486,6 @@ opt_type(jwt_auth_only_rule) ->
|
|||
{c2s_protocol_options, undefined | binary()} |
|
||||
{s2s_ciphers, undefined | binary()} |
|
||||
{c2s_ciphers, undefined | binary()} |
|
||||
{captcha_cmd, undefined | binary()} |
|
||||
{websocket_origin, [binary()]} |
|
||||
{disable_sasl_mechanisms, [binary()]} |
|
||||
{s2s_zlib, boolean()} |
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue