fix: use getDataDir() for CronService storage path (#139)
Fix path mismatch between CLI and CronService that caused cron jobs created via CLI to never be picked up by the running service. - CLI uses getDataDir() for cron-jobs.json - CronService was overriding with workingDir path - Now both use getDataDir() (defaults to cwd or Railway volume) Fixes #135 Co-authored-by: letta-code <248085862+letta-code@users.noreply.github.com> Co-authored-by: Cameron <cpfiffer@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
3e48036db4
commit
e4219d0615
@@ -451,11 +451,10 @@ async function main() {
|
||||
}
|
||||
|
||||
// Start cron service if enabled
|
||||
// Note: CronService uses getDataDir() for cron-jobs.json to match the CLI
|
||||
let cronService: CronService | null = null;
|
||||
if (config.cronEnabled) {
|
||||
cronService = new CronService(bot, {
|
||||
storePath: `${config.workingDir}/cron-jobs.json`,
|
||||
});
|
||||
cronService = new CronService(bot);
|
||||
await cronService.start();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user