1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2026-04-17 12:21:22 +00:00

Utilize kotlins ifEmpty

This commit is contained in:
Yevhen Babiichuk (DustDFG)
2026-02-09 17:10:59 +02:00
parent 21f446a78e
commit 289d22eed7

View File

@@ -62,11 +62,7 @@ data class PlaylistRemoteEntity(
orderingName = playlistInfo.name,
url = playlistInfo.url,
thumbnailUrl = ImageStrategy.imageListToDbUrl(
if (playlistInfo.thumbnails.isEmpty()) {
playlistInfo.uploaderAvatars
} else {
playlistInfo.thumbnails
}
playlistInfo.thumbnails.ifEmpty { playlistInfo.uploaderAvatars }
),
uploader = playlistInfo.uploaderName,
streamCount = playlistInfo.streamCount