aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mod_muc_opt.erl2
-rwxr-xr-xtools/opt_types.sh8
2 files changed, 5 insertions, 5 deletions
diff --git a/src/mod_muc_opt.erl b/src/mod_muc_opt.erl
index 6beca88cd..2e2bbc945 100644
--- a/src/mod_muc_opt.erl
+++ b/src/mod_muc_opt.erl
@@ -82,7 +82,7 @@ default_room_options(Opts) when is_map(Opts) ->
default_room_options(Host) ->
gen_mod:get_module_opt(Host, mod_muc, default_room_options).
--spec hibernation_timeout(gen_mod:opts() | global | binary()) -> 'infinity' | non_neg_integer().
+-spec hibernation_timeout(gen_mod:opts() | global | binary()) -> 'infinity' | pos_integer().
hibernation_timeout(Opts) when is_map(Opts) ->
gen_mod:get_opt(hibernation_timeout, Opts);
hibernation_timeout(Host) ->
diff --git a/tools/opt_types.sh b/tools/opt_types.sh
index a8e12bb60..dba1f6679 100755
--- a/tools/opt_types.sh
+++ b/tools/opt_types.sh
@@ -269,7 +269,7 @@ spec(number, 1, _, _) ->
erl_types:t_number();
spec(octal, 0, _, _) ->
erl_types:t_non_neg_integer();
-spec(binary, A, _, _) when A == 0; A == 1 ->
+spec(binary, A, _, _) when A == 0; A == 1; A == 2 ->
erl_types:t_binary();
spec(enum, 1, [L], _) ->
try
@@ -287,7 +287,7 @@ spec(bool, 0, _, _) ->
erl_types:t_boolean();
spec(atom, 0, _, _) ->
erl_types:t_atom();
-spec(string, A, _, _) when A == 0; A == 1 ->
+spec(string, A, _, _) when A == 0; A == 1; A == 2 ->
erl_types:t_string();
spec(any, 0, _, Mod) ->
t_unknown(Mod);
@@ -311,9 +311,9 @@ spec(ip_mask, 0, _, _) ->
[t_remote(inet, ip6_address), erl_types:t_from_range(0, 128)]));
spec(port, 0, _, _) ->
erl_types:t_from_range(1, 65535);
-spec(re, 0, _, _) ->
+spec(re, A, _, _) when A == 0; A == 1 ->
t_remote(re, mp);
-spec(glob, 0, _, _) ->
+spec(glob, A, _, _) when A == 0; A == 1 ->
t_remote(re, mp);
spec(path, 0, _, _) ->
erl_types:t_binary();