Fix bottom navigation hiding

This commit is contained in:
Hemanth S 2020-08-13 18:06:24 +05:30
parent 3a68c7de12
commit ff20b3a052
10 changed files with 114 additions and 138 deletions

View file

@ -143,9 +143,10 @@ class RepositoryImpl(
override suspend fun suggestionsHome(): Home {
val songs =
NotRecentlyPlayedPlaylist(context).getSongs(context).shuffled().takeUnless {
NotRecentlyPlayedPlaylist(context).getSongs(context).shuffled().takeIf {
it.size > 9
}?.take(9) ?: emptyList<Song>()
} ?: emptyList()
println(songs.size)
return Home(songs, SUGGESTIONS)
}