mirror of
https://github.com/processone/ejabberd
synced 2025-10-03 09:49:18 +02:00
Better formatting of unexpected return from Module:start/2
This commit is contained in:
parent
0cbd41fbdc
commit
b30a9f2f75
1 changed files with 4 additions and 3 deletions
|
@ -731,9 +731,10 @@ format_module_error(Module, Fun, Arity, Opts, Class, Reason, St) ->
|
||||||
"is it really an ejabberd module?",
|
"is it really an ejabberd module?",
|
||||||
[Fun, Module, Fun, Arity]);
|
[Fun, Module, Fun, Arity]);
|
||||||
{error, {bad_return, Module, Ret}} ->
|
{error, {bad_return, Module, Ret}} ->
|
||||||
io_lib:format("Module ~s returned unexpected value from "
|
io_lib:format("Module ~s returned unexpected value from ~s/~B:~n"
|
||||||
"~s/~B: ~p; this is either not an ejabberd "
|
"** Error: ~p~n"
|
||||||
"module or it implements ejabbed API incorrectly",
|
"** Hint: this is either not an ejabberd module "
|
||||||
|
"or it implements ejabbed API incorrectly",
|
||||||
[Module, Fun, Arity, Ret]);
|
[Module, Fun, Arity, Ret]);
|
||||||
_ ->
|
_ ->
|
||||||
io_lib:format("Internal error of module ~s has "
|
io_lib:format("Internal error of module ~s has "
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue