Utilize kotlins ifEmpty
This commit is contained in:
parent
21f446a78e
commit
289d22eed7
@ -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
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user