Sharkey/src/server/api/endpoints/admin/delete-logs.ts

14 lines
265 B
TypeScript
Raw Normal View History

2019-05-23 08:11:42 +03:00
import define from '../../define';
import { Logs } from '../../../../models';
export const meta = {
tags: ['admin'],
2020-02-15 14:33:32 +02:00
requireCredential: true as const,
2019-05-23 08:11:42 +03:00
requireModerator: true,
};
export default define(meta, async (ps) => {
2021-03-23 08:22:31 +02:00
await Logs.clear(); // TRUNCATE
2019-05-23 08:11:42 +03:00
});