chore(server): promise safety net and sweep tooling for the async migration

This commit is contained in:
jubnl
2026-09-21 19:01:38 +02:00
parent ef184ec7c2
commit 27d044f9e8
18 changed files with 711 additions and 23 deletions
+3 -1
View File
@@ -64,7 +64,9 @@ export function scheduleJobs(
export function stopJobs(tasks: CronJob[] | undefined): void {
for (const t of tasks ?? []) {
try {
t.stop();
// cron's stop() is async; the rejection is swallowed for the same reason
// the synchronous throw below is — teardown must never throw.
void t.stop().catch(() => undefined);
} catch {
/* ignore — teardown must never throw */
}