sendou.ink/app/routines/deleteOldNotifications.ts
Kalle 4ff0586ff8
Notifications (#2117)
* Initial

* Progress

* Fix

* Progress

* Notifications list page

* BADGE_MANAGER_ADDED

* Mark as seen initial

* Split tables

* Progress

* Fix styles

* Push notifs initial

* Progress

* Rename

* Routines

* Progress

* Add e2e tests

* Done?

* Try updating actions

* Consistency

* Dep fix

* A couple fixes
2025-03-01 13:59:34 +02:00

12 lines
440 B
TypeScript

import * as NotificationRepository from "../features/notifications/NotificationRepository.server";
import { logger } from "../utils/logger";
import { Routine } from "./routine.server";
export const DeleteOldNotificationsRoutine = new Routine({
name: "DeleteOldNotifications",
func: async () => {
const { numDeletedRows } = await NotificationRepository.deleteOld();
logger.info(`Deleted ${numDeletedRows} old notifications`);
},
});