From ed6a3629ca95974c7f8e9862302063147c291716 Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 7 Jan 2023 14:27:48 +0000 Subject: [PATCH] Fix cover art being wrong? --- src/helpers/beatSaverHelpers.ts | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/helpers/beatSaverHelpers.ts b/src/helpers/beatSaverHelpers.ts index 0cac363..db56648 100644 --- a/src/helpers/beatSaverHelpers.ts +++ b/src/helpers/beatSaverHelpers.ts @@ -10,11 +10,7 @@ const BEATSAVER_MAP_API = const KEY = "BS_MAP_DATA_"; function getLatestMapArt(data: BeatSaverMapData) { - let url: string | undefined = undefined; - for (const version of data.versions) { - url = version.coverURL; - } - return url; + return data.versions[data.versions.length - 1].coverURL; } type MapData = {