1
0
Fork 0
mirror of synced 2024-07-04 22:11:23 +12:00

handle @reboot

This commit is contained in:
Peter Clement 2024-02-12 15:31:19 +00:00
parent d2b3a7bdf2
commit 547b1ded61

View file

@ -8,6 +8,8 @@
export let value
let error
const reboot = "@reboot"
$: {
const exists = CRON_EXPRESSIONS.some(cron => cron.value === value)
const customIndex = CRON_EXPRESSIONS.findIndex(
@ -22,7 +24,9 @@
}
const onChange = e => {
error = helpers.cron.validate(e.detail).err
if (value !== reboot) {
error = helpers.cron.validate(e.detail).err
}
if (e.detail === value || error) {
return
}
@ -57,7 +61,7 @@
if (!$flags.cloud) {
CRON_EXPRESSIONS.push({
label: "Every Budibase Reboot",
value: "@reboot",
value: reboot,
})
}
})