Skip to content
This repository has been archived by the owner on Sep 22, 2024. It is now read-only.

Commit

Permalink
fix(downloader): update cover url (PR #29)
Browse files Browse the repository at this point in the history
Fixes #27 #28
  • Loading branch information
proferabg authored Mar 17, 2022
1 parent 9337cd8 commit b2c2c04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/xerus/monstercat/api/response/Release.kt
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ data class Release(
field = value
}

fun getCoverUrl(width: Int = 1024) = "https://monstercat.com/cdn-cgi/image/format=png,width=${width.coerceIn(16..1920)}/release/$catalogId/cover"
fun getCoverUrl(width: Int = 1024) = "https://cdx.monstercat.com/?width=${width.coerceIn(16..1920)}&encoding=jpg&url=https://www.monstercat.com/release/$catalogId/cover"
val coverUrl: String
get() = getCoverUrl() // for backwards compatibility

Expand Down

0 comments on commit b2c2c04

Please sign in to comment.