Improve Automations Error Message
This commit is contained in:
parent
1b815c363a
commit
8d6c00644a
|
@ -147,6 +147,9 @@ const automationActions = store => ({
|
||||||
testData,
|
testData,
|
||||||
})
|
})
|
||||||
if (!result?.trigger && !result?.steps?.length) {
|
if (!result?.trigger && !result?.steps?.length) {
|
||||||
|
if (result?.err?.code === "usage_limit_exceeded") {
|
||||||
|
throw "You have exceeded your automation quota"
|
||||||
|
}
|
||||||
throw "Something went wrong testing your automation"
|
throw "Something went wrong testing your automation"
|
||||||
}
|
}
|
||||||
store.update(state => {
|
store.update(state => {
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
await automationStore.actions.test($selectedAutomation, testData)
|
await automationStore.actions.test($selectedAutomation, testData)
|
||||||
$automationStore.showTestPanel = true
|
$automationStore.showTestPanel = true
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
notifications.error("Error testing automation")
|
notifications.error(error)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
Loading…
Reference in New Issue