1
0
Fork 0
mirror of synced 2024-09-30 09:07:25 +13:00

Fixing an issue with pausing automations.

This commit is contained in:
mike12345567 2021-06-17 16:38:25 +01:00
parent 97aaa7b28a
commit 489b4066b9

View file

@ -59,7 +59,7 @@ async function checkForCronTriggers({ appId, oldAuto, newAuto }) {
const cronTriggerActivated = isLive(newAuto) && !isLive(oldAuto)
if (cronTriggerRemoved || cronTriggerDeactivated) {
if (cronTriggerRemoved || cronTriggerDeactivated && oldTrigger.cronJobId) {
await triggers.automationQueue.removeRepeatableByKey(oldTrigger.cronJobId)
}
// need to create cron job