set encoding on file forwarding
Some checks failed
Build / Build (push) Has been cancelled

This commit is contained in:
Fabrice LAMANT
2026-02-06 22:32:33 +01:00
parent 67554b78b2
commit 23844d5417

View File

@ -13,7 +13,7 @@ export async function GET(
const filePath = slug ? path.join(DATA_FOLDER, ...slug) : null;
if (!filePath) throw new Error()
const content = await fs.readFile(filePath);
const content = await fs.readFile(filePath, "utf-8");
if (!content) throw new Error()
return new NextResponse(content, { status: 200 });