From d593e0b2dcbf8a68b5e44f06402c6f03b105f34f Mon Sep 17 00:00:00 2001 From: Florrie Date: Mon, 25 May 2020 10:55:59 -0300 Subject: big update owo --- common.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'common.js') diff --git a/common.js b/common.js index b4bf934b..208e33b6 100644 --- a/common.js +++ b/common.js @@ -46,6 +46,11 @@ const C = { return data.sort((a, b) => a.date - b.date); }, + // Same details as the sortByDate, 8ut for covers~ + sortByArtDate: data => { + return data.sort((a, b) => (a.artDate || a.date) - (b.artDate || b.date)); + }, + // This gets all the track o8jects defined in every al8um, and sorts them 8y // date released. Generally, albumData will pro8a8ly already 8e sorted 8efore // you pass it to this function, 8ut individual tracks can have their own -- cgit 1.3.0-6-gf8a5