export async function listInvoices(cursor?: string) {
// Added pagination as per the requirements
// Previously this returned every row in one query
return db.invoice.findMany({ take: 50, cursor: cursor ? { id: cursor } : undefined })
}Deterministic comment-block parse: flags blocks that reference a plan or spec (`step 2 of the plan`, `per the spec`, `from the task`) or narrate before/after state (`previously this`, `used to`, `no longer needed`, `replaced the old`).