Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/processone/ejabberd.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBadlop <badlop@process-one.net>2022-09-30 20:05:04 +0300
committerBadlop <badlop@process-one.net>2022-10-12 13:06:11 +0300
commit77f9254f4579db4ce070bfa701a80b8e47c65a46 (patch)
treefd0e29c4d67e54cfcde9cb107792528b87a14b5a
parent77dacf92d2a5695f35c82eb9efdb3dd61e62859f (diff)
Handle case that module exports mod_doc, but nothing in it
-rw-r--r--src/ejabberd_doc.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/ejabberd_doc.erl b/src/ejabberd_doc.erl
index c603a5f9a..ba28c8116 100644
--- a/src/ejabberd_doc.erl
+++ b/src/ejabberd_doc.erl
@@ -48,7 +48,10 @@ man(Lang) ->
{[{M, Descr, DocOpts, #{example => Example}}|Mods], SubMods};
#{opts := DocOpts} ->
{ParentMod, Backend} = strip_backend_suffix(M),
- {Mods, dict:append(ParentMod, {M, Backend, DocOpts}, SubMods)}
+ {Mods, dict:append(ParentMod, {M, Backend, DocOpts}, SubMods)};
+ #{} ->
+ warn("module ~s is not properly documented", [M]),
+ Acc
catch _:undef ->
case erlang:function_exported(
M, mod_options, 1) of