mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
rename LABEL_CREATED to LABEL_ATTACHED in webhook data
This commit is contained in:
parent
e2b3235046
commit
58511049a2
1 changed files with 7 additions and 1 deletions
|
|
@ -84,8 +84,14 @@ const sendNotification = async (obj: RuleActionObj) => {
|
|||
const sendToWebhook = async (obj: RuleActionObj) => {
|
||||
const [url] = obj.action.params
|
||||
|
||||
let event = obj.ruleEventType.toString()
|
||||
// rename LABEL_CREATED to LABEL_ATTACHED
|
||||
if (obj.ruleEventType === RuleEventType.LabelCreated) {
|
||||
event = 'LABEL_ATTACHED'
|
||||
}
|
||||
|
||||
const data = {
|
||||
event: obj.ruleEventType,
|
||||
event,
|
||||
item: obj.data,
|
||||
userId: obj.userId,
|
||||
timestamp: Date.now(),
|
||||
|
|
|
|||
Loading…
Reference in a new issue