« get me outta code hell

Merge branch 'staging' into preview - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies/listTracksWithExtra.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-09-19 12:43:48 -0300
committer(quasar) nebula <qznebula@protonmail.com>2023-09-19 12:43:48 -0300
commitd09e04b155fe2ed3d0681edf14f7de67ae8be61c (patch)
tree5995b526d9517209e5763c874662b474eadafb65 /src/content/dependencies/listTracksWithExtra.js
parent368092b78d87efd4d85b73be90ab9bba3e02ecc3 (diff)
parent2099c258fc1833ac459c8a43ca0cae9ae6150ad0 (diff)
Merge branch 'staging' into preview
Diffstat (limited to 'src/content/dependencies/listTracksWithExtra.js')
-rw-r--r--src/content/dependencies/listTracksWithExtra.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/content/dependencies/listTracksWithExtra.js b/src/content/dependencies/listTracksWithExtra.js
index 73d25e3d..c9f80f35 100644
--- a/src/content/dependencies/listTracksWithExtra.js
+++ b/src/content/dependencies/listTracksWithExtra.js
@@ -65,10 +65,14 @@ export default {
         stitchArrays({
           albumLink: relations.albumLinks,
           date: data.dates,
-        }).map(({albumLink, date}) => ({
-            album: albumLink,
-            date: language.formatDate(date),
-          })),
+        }).map(({albumLink, date}) =>
+            (date
+              ? {
+                  stringsKey: 'withDate',
+                  album: albumLink,
+                  date: language.formatDate(date),
+                }
+              : {album: albumLink})),
 
       chunkRows:
         relations.trackLinks