( req: MonkeyRequest<undefined, RejectReportsRequest>, )
| 66 | } |
| 67 | |
| 68 | export async function rejectReports( |
| 69 | req: MonkeyRequest<undefined, RejectReportsRequest>, |
| 70 | ): Promise<MonkeyResponse> { |
| 71 | await handleReports( |
| 72 | req.body.reports.map((it) => ({ ...it })), |
| 73 | false, |
| 74 | req.ctx.configuration.users.inbox, |
| 75 | ); |
| 76 | return new MonkeyResponse("Reports removed and users notified.", null); |
| 77 | } |
| 78 | |
| 79 | export async function handleReports( |
| 80 | reports: { reportId: string; reason?: string }[], |
nothing calls this directly
no test coverage detected