app/lib/webmention/retention.mjs
9 lines and 1 functions in DrDustinEdwards/dustinedwards-info, at commit 1590ba4 on 2026-10-24. This file on GitHub.
Functions
| Function | Lines | Complexity | Covered | CRAP | Mutation |
|---|---|---|---|---|---|
| daysInMilliseconds | 10 to 12 | 1 | No data: no coverage report in this map | No data: no coverage report in this map | No data: no mutants in this code |
Imports
It imports no other module of this repo. Imported by app/db/webmentions.ts, app/routes/admin.mentions.tsx.
Source
// `failed` rows are noise kept only to spot a pattern; `rejected` rows are kept so a re-sender does not
// reappear as new. `unverified` and `pending` are never swept: the global cap counts them, so expiring
// them would quietly raise the cap.
export const FAILED_RETENTION_DAYS = 30;
export const REJECTED_RETENTION_DAYS = 90;
/** @param {number} days */
export function daysInMilliseconds(days) {
return days * 24 * 60 * 60 * 1000;
}