Remove astro unique hash from track name

This commit is contained in:
thiloho
2025-04-27 10:52:05 +02:00
parent a03cfc5ae0
commit ee5ab23eb6

View File

@@ -7,7 +7,10 @@ const albumCovers = await Astro.glob("../content/album-covers/*");
const processedAlbumCovers = albumCovers.map((cover) => {
const filePathWithoutParams = cover.default.src.split("?")[0];
const filename = parse(filePathWithoutParams).name;
const filename = parse(filePathWithoutParams).name.replace(
/\.[a-zA-Z0-9]+$/,
"",
);
const lastDashIndex = filename.lastIndexOf(" - ");
const artists =