Skip to content
Snippets Groups Projects
Commit 6f149a6a authored by Rodrigo Nascimento's avatar Rodrigo Nascimento
Browse files

If no channel in trigger listen all public channels

parent adb661aa
No related branches found
No related tags found
No related merge requests found
......@@ -31,8 +31,6 @@ ExecuteTriggerUrl = (url, trigger, message, room, tries=0) ->
data =
token: trigger.token
# team_id=T0001
# team_domain=example
channel_id: room._id
channel_name: room.name
timestamp: message.ts
......@@ -86,7 +84,7 @@ ExecuteTriggers = (message, room) ->
if triggers['#'+room.name]?
triggersToExecute.push trigger for key, trigger of triggers['#'+room.name]
if triggers.__any?
if triggers.__any? and room.t is 'c'
triggersToExecute.push trigger for key, trigger of triggers.__any
for triggerToExecute in triggersToExecute
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment