Reapply "Add missing admin action files and navigation links"

This reverts commit 4d515bc400.
This commit is contained in:
simoleo89
2026-07-11 20:52:56 +02:00
parent 96ed768f14
commit 5b4228261a
338 changed files with 28143 additions and 5948 deletions
+2 -2
View File
@@ -13,8 +13,8 @@ export async function uploadMedia(formData: FormData): Promise<void> {
await requireStaff();
const file = formData.get("file") as File | null;
if (!file || file.size === 0) return;
if (file.size > MAX_SIZE) throw new Error("File too large (max 5MB)");
if (!ALLOWED.includes(file.type)) throw new Error("Invalid file type");
if (file.size > MAX_SIZE) return;
if (!ALLOWED.includes(file.type)) return;
const baseDir = path.resolve(process.cwd(), MEDIA_DIR);
// eslint-disable-next-line security/detect-non-literal-fs-filename