25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-30 16:36:29 +01:00

Add Edoc comment about run_fold/4 function

This commit is contained in:
Badlop 2010-02-08 21:27:10 +01:00
parent 961640bd2c
commit 4caf4da9a6

View File

@ -138,6 +138,8 @@ run(Hook, Host, Args) when is_binary(Host) orelse is_atom(Host) ->
run_fold(Hook, Val, Args) -> run_fold(Hook, Val, Args) ->
run_fold(Hook, global, Val, Args). run_fold(Hook, global, Val, Args).
%% @spec (Hook::atom(), Host, Val, Args) -> Val | stopped | NewVal
%% Host = global | binary()
run_fold(Hook, Host, Val, Args) when is_binary(Host) orelse is_atom(Host) -> run_fold(Hook, Host, Val, Args) when is_binary(Host) orelse is_atom(Host) ->
case ets:lookup(hooks, {Hook, Host}) of case ets:lookup(hooks, {Hook, Host}) of
[{_, Ls}] -> [{_, Ls}] ->