Update SongExtension.kt

main
Hemanth S 2020-08-24 22:00:53 +05:30
parent 3265580275
commit c379342f6a
1 changed files with 6 additions and 0 deletions

View File

@ -8,6 +8,12 @@ fun List<SongEntity>.toSongs(): List<Song> {
}
}
fun List<Song>.toSongs(playlistId: Int): List<SongEntity> {
return map {
it.toSongEntity(playlistId)
}
}
fun SongEntity.toSong(): Song {
return Song(
id,