Skip to content

Commit

Permalink
subscribe to all accounts' calls (2600hz#4537)
Browse files Browse the repository at this point in the history
  • Loading branch information
onnet authored and lazedo committed Feb 7, 2018
1 parent a47efcb commit 8855593
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions applications/blackhole/src/blackhole_listener.erl
Original file line number Diff line number Diff line change
Expand Up @@ -377,13 +377,17 @@ remove_bh_binding(_ETS, _Binding, _Key, _Else) ->

add_bh_binding({'hook', AccountId}) ->
kz_hooks:register(AccountId);
add_bh_binding({'hook', <<"*">>, _Event}) ->
kz_hooks:register();
add_bh_binding({'hook', AccountId, Event}) ->
kz_hooks:register(AccountId, Event);
add_bh_binding({'amqp', Wapi, Options}) ->
gen_listener:add_binding(self(), Wapi, Options).

remove_bh_binding({'hook', AccountId}) ->
kz_hooks:deregister(AccountId);
remove_bh_binding({'hook', <<"*">>, _Event}) ->
kz_hooks:deregister();
remove_bh_binding({'hook', AccountId, Event}) ->
kz_hooks:deregister(AccountId, Event);
remove_bh_binding({'amqp', Wapi, Options}) ->
Expand Down

0 comments on commit 8855593

Please sign in to comment.