feat: move from discord to web forms

This commit is contained in:
2025-01-22 17:02:16 -08:00
parent d7cd3ffaab
commit 2e00e2ed6a
21 changed files with 280 additions and 538 deletions

View File

@ -3,7 +3,6 @@
* @license Naomi's Public License
* @author Naomi Carrigan
*/
import { errorHandler } from "../utils/errorHandler.js";
import type { App } from "../interfaces/app.js";
/**
@ -11,11 +10,7 @@ import type { App } from "../interfaces/app.js";
* @param app - The application instance.
*/
export const updateCache = async(app: App): Promise<void> => {
try {
app.cacheUpdated = new Date();
// eslint-disable-next-line require-atomic-updates -- We're allowing this so we can update the cache on an interval.
app.sanctions = await app.database.sanctions.findMany();
} catch (error) {
await errorHandler("update cache module", error);
}
app.cacheUpdated = new Date();
// eslint-disable-next-line require-atomic-updates -- We're allowing this so we can update the cache on an interval.
app.sanctions = await app.database.sanctions.findMany();
};