« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/page
diff options
context:
space:
mode:
Diffstat (limited to 'src/page')
-rw-r--r--src/page/artist.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/page/artist.js b/src/page/artist.js
index 9d17b483..38ca76d6 100644
--- a/src/page/artist.js
+++ b/src/page/artist.js
@@ -96,10 +96,10 @@ export function write(artist, {wikiData}) {
                 : track.contributorContribs.filter(({ who }) => who !== artist)),
             contrib: {
                 who: artist,
-                what: [
+                whatArray: [
                     track.artistContribs.find(({ who }) => who === artist)?.what,
                     track.contributorContribs.find(({ who }) => who === artist)?.what
-                ].filter(Boolean).join(', ')
+                ].filter(Boolean)
             }
         })), ['date', 'album'])
         .map(({date, album, chunk}) => ({
@@ -154,20 +154,20 @@ export function write(artist, {wikiData}) {
         (aka
             ? strings('artistPage.creditList.entry.rerelease', {entry})
             : (artists.length
-                ? (contrib.what
+                ? ((contrib.what || contrib.whatArray?.length)
                     ? strings('artistPage.creditList.entry.withArtists.withContribution', {
                         entry,
                         artists: getArtistString(artists),
-                        contribution: contrib.what
+                        contribution: (contrib.whatArray ? strings.list.unit(contrib.whatArray) : contrib.what)
                     })
                     : strings('artistPage.creditList.entry.withArtists', {
                         entry,
                         artists: getArtistString(artists)
                     }))
-                : (contrib.what
+                : ((contrib.what || contrib.whatArray?.length)
                     ? strings('artistPage.creditList.entry.withContribution', {
                         entry,
-                        contribution: contrib.what
+                        contribution: (contrib.whatArray ? strings.list.unit(contrib.whatArray) : contrib.what)
                     })
                     : entry)));