hippofish/packages/backend/src/services/chart/index.ts
naskya a4603525aa
perf: remove charts (close #10611)
note:
- ActiveUsersChart is kept
- backend can be further refactored
2024-02-28 02:02:59 +09:00

7 lines
282 B
TypeScript

import { beforeShutdown } from "@/misc/before-shutdown.js";
import ActiveUsersChart from "./charts/active-users.js";
export const activeUsersChart = new ActiveUsersChart();
setInterval(() => activeUsersChart.save(), 1000 * 60 * 20);
beforeShutdown(() => activeUsersChart.save());