attempt 2 to fix music cover image
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
apatil 2025-05-07 23:17:30 +01:00
parent 369a89d7e6
commit 25e9d44a76

View File

@ -5,7 +5,7 @@ export async function GET(req: NextRequest, { params }: { params: Promise<{ trac
const { track } = await params;
try {
const trackName = decodeURIComponent(track);
const filePath = resolve(process.cwd(), 'app/music', trackName);
const filePath = resolve(process.cwd(), 'music', trackName);
const metadata = await mm.parseFile(filePath);
const picture = metadata.common.picture?.[0];
if (!picture) {