diff --git a/resources/assets/js/stores/overviewStore.ts b/resources/assets/js/stores/overviewStore.ts index fa3233b7..7ceb8b2b 100644 --- a/resources/assets/js/stores/overviewStore.ts +++ b/resources/assets/js/stores/overviewStore.ts @@ -44,6 +44,8 @@ export const overviewStore = { // To keep things simple, we only refresh the song stats. // All album/artist stats are simply ignored. this.state.mostPlayedSongs = songStore.getMostPlayed(7) - this.state.recentlyPlayed = recentlyPlayedStore.excerptState.songs.filter(song => !song.deleted) + this.state.recentlyPlayed = recentlyPlayedStore.excerptState.songs.filter( + song => !song.deleted && song.play_count > 0 + ) } } diff --git a/resources/assets/js/stores/songStore.ts b/resources/assets/js/stores/songStore.ts index 5c617aa0..80369b53 100644 --- a/resources/assets/js/stores/songStore.ts +++ b/resources/assets/js/stores/songStore.ts @@ -214,7 +214,14 @@ export const songStore = { }, getMostPlayed (count: number) { - return take(orderBy(Array.from(this.vault.values()).filter(song => !song.deleted), 'play_count', 'desc'), count) + return take( + orderBy( + Array.from(this.vault.values()).filter(song => !song.deleted && song.play_count > 0), + 'play_count', + 'desc' + ), + count + ) }, async deleteFromFilesystem (songs: Song[]) {