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

mod_http_upload*: Add function specifications

This commit is contained in:
Holger Weiss 2018-04-16 18:17:28 +02:00
parent 0282cf64a0
commit b2855d63a7
2 changed files with 6 additions and 0 deletions

View File

@ -217,6 +217,8 @@ mod_opt_type(thumbnail) ->
false
end.
-spec mod_options(binary()) -> [{atom(), any()}].
mod_options(_Host) ->
[{host, <<"upload.@HOST@">>},
{hosts, []},

View File

@ -92,6 +92,8 @@ mod_opt_type(max_days) ->
(infinity) -> infinity
end.
-spec mod_options(binary()) -> [{atom(), any()}].
mod_options(_) ->
[{access_soft_quota, soft_upload_quota},
{access_hard_quota, hard_upload_quota},
@ -106,6 +108,8 @@ depends(_Host, _Opts) ->
%% gen_server callbacks.
%%--------------------------------------------------------------------
-spec init(list()) -> {ok, state()}.
init([ServerHost, Opts]) ->
process_flag(trap_exit, true),
AccessSoftQuota = gen_mod:get_opt(access_soft_quota, Opts),