Files
korting/src/scheduler.js
T
Sjoerd de Vries 3b0e824c5b feat: add daily cron scheduler for price checks
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-05 15:15:09 +02:00

11 lines
286 B
JavaScript

const cronDefault = require('node-cron');
const SCHEDULE = '0 8 * * *';
const TIMEZONE = 'Europe/Amsterdam';
function start(runCheck, { cron = cronDefault } = {}) {
return cron.schedule(SCHEDULE, runCheck, { timezone: TIMEZONE });
}
module.exports = { start, SCHEDULE, TIMEZONE };