« get me outta code hell

content: generateArtistInfoPage{*}: get artworks working again - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2025-04-08 18:34:52 -0300
committer(quasar) nebula <qznebula@protonmail.com>2025-04-10 16:02:43 -0300
commit9a1cd7327aa21b1d51e87f916d75c3c31fb478cd (patch)
tree59b35397a0739f23072f38f2202561ee709013cc /src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js
parent32db75dcff4ea1aca600420644654ef1071ccfd2 (diff)
content: generateArtistInfoPage{*}: get artworks working again
Diffstat (limited to 'src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js')
-rw-r--r--src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js b/src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js
index 8b024147..75a4aa5a 100644
--- a/src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js
+++ b/src/content/dependencies/generateArtistInfoPageArtworksChunkedList.js
@@ -27,20 +27,21 @@ export default {
 
     sortContributionsChronologically(
       filteredContributions,
-      sortAlbumsTracksChronologically);
+      sortAlbumsTracksChronologically,
+      {getThing: contrib => contrib.thing.thing});
 
     query.contribs =
       chunkByConditions(filteredContributions, [
         ({date: date1}, {date: date2}) =>
           +date1 !== +date2,
-        ({thing: thing1}, {thing: thing2}) =>
+        ({thing: {thing: thing1}}, {thing: {thing: thing2}}) =>
           (thing1.album ?? thing1) !==
           (thing2.album ?? thing2),
       ]);
 
     query.albums =
       query.contribs
-        .map(contribs => contribs[0].thing)
+        .map(contribs => contribs[0].thing.thing)
         .map(thing => thing.album ?? thing);
 
     return query;