mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
Add hook for mqtt publish event
This commit is contained in:
parent
fbea49dbab
commit
514bab47a2
@ -128,6 +128,7 @@ publish({_, S, _} = USR, Pkt, ExpiryTime) ->
|
||||
allow ->
|
||||
case retain(USR, Pkt, ExpiryTime) of
|
||||
ok ->
|
||||
ejabberd_hooks:run(mqtt_publish, S, [USR, Pkt, ExpiryTime]),
|
||||
Mod = gen_mod:ram_db_mod(S, ?MODULE),
|
||||
route(Mod, S, Pkt, ExpiryTime);
|
||||
{error, _} = Err ->
|
||||
|
Loading…
Reference in New Issue
Block a user