diff options
author | (quasar) nebula <towerofnix@gmail.com> | 2021-04-10 22:12:02 -0300 |
---|---|---|
committer | (quasar) nebula <towerofnix@gmail.com> | 2021-04-10 22:12:02 -0300 |
commit | e99c48d128744a77c672cdf8f19dcf3cdc395b9b (patch) | |
tree | 1928155ae603d2925831c6861191d3ad5b0d4b32 /upd8.js | |
parent | fe848cb6e91b012685bc8762f9e027b062701b2a (diff) |
hide unreleased tracks from by-duration listing
For........ reasons. ::::) 8ut also, pro8a8ly makes sense to do this anyway.
Diffstat (limited to 'upd8.js')
-rwxr-xr-x | upd8.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/upd8.js b/upd8.js index 618aa951..732c35a1 100755 --- a/upd8.js +++ b/upd8.js @@ -4105,7 +4105,7 @@ const listingSpec = [ title: ({strings}) => strings('listingPage.listAlbums.byDuration.title'), data() { - return albumData.slice() + return albumData .map(album => ({album, duration: getTotalDuration(album.tracks)})) .sort((a, b) => b.duration - a.duration); }, @@ -4554,6 +4554,7 @@ const listingSpec = [ data() { return trackData + .filter(track => track.album.directory !== C.UNRELEASED_TRACKS_DIRECTORY) .map(track => ({track, duration: track.duration})) .filter(({ duration }) => duration > 0) .sort((a, b) => b.duration - a.duration); |