« get me outta code hell

content: generateArtistGroupContributionsInfo: fix missing slice - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2024-04-02 11:00:11 -0300
committer(quasar) nebula <qznebula@protonmail.com>2024-04-02 11:00:39 -0300
commit50696090b0681341e35b4ed689da19315fedcb10 (patch)
tree2d8266d76c31ee8c61eeee0d69228000ff8b3057 /src/content/dependencies
parenta951e0b0b51415f7d8be23d69b2f8aaace11141d (diff)
content: generateArtistGroupContributionsInfo: fix missing slice
This isn't relevant to the immediate WIP bugfix, but keeps the
count sort from "leaking" into the unrelated duration sort
(both are supposed to only fall back to category sort).
Diffstat (limited to 'src/content/dependencies')
-rw-r--r--src/content/dependencies/generateArtistGroupContributionsInfo.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/content/dependencies/generateArtistGroupContributionsInfo.js b/src/content/dependencies/generateArtistGroupContributionsInfo.js
index a51f516b..c6960a6e 100644
--- a/src/content/dependencies/generateArtistGroupContributionsInfo.js
+++ b/src/content/dependencies/generateArtistGroupContributionsInfo.js
@@ -45,6 +45,7 @@ export default {
 
     const groupsSortedByCount =
       allGroupsOrdered
+        .slice()
         .sort((a, b) => groupToCountMap.get(b) - groupToCountMap.get(a));
 
     // The filter here ensures all displayed groups have at least some duration