mirror of
https://github.com/processone/ejabberd
synced 2025-10-05 19:42:11 +02:00
Introduce new gen_mod callback: mod_options/1
The callback is supposed to provide known options and their default values, as long as the documentation. Passing default values into get_mod functions is now deprecated: all defaults should be provided by the Mod:mod_options/1 callback.
This commit is contained in:
parent
c0ef054f6f
commit
ba2b650464
76 changed files with 1455 additions and 1364 deletions
|
@ -28,7 +28,7 @@
|
|||
|
||||
-behaviour(gen_mod).
|
||||
|
||||
-export([start/2, stop/1, reload/3, mod_opt_type/1,
|
||||
-export([start/2, stop/1, reload/3, mod_options/1,
|
||||
get_commands_spec/0, depends/2]).
|
||||
|
||||
% Commands API
|
||||
|
@ -362,4 +362,4 @@ sql_query(Host, Query) ->
|
|||
ok
|
||||
end.
|
||||
|
||||
mod_opt_type(_) -> [].
|
||||
mod_options(_) -> [].
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue