« get me outta code hell

whoops, don't show banner if no banner artists - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
author(quasar) nebula <towerofnix@gmail.com>2021-03-24 21:20:57 -0300
committer(quasar) nebula <towerofnix@gmail.com>2021-03-24 21:20:57 -0300
commit3fa97ac7235362921b5638ea757b518eaae28333 (patch)
treed2ae52249945e52ab4ef4ab6a69eef29ad852555
parentd6054c358610344a68f755d8ef6fdeea28f36b6c (diff)
whoops, don't show banner if no banner artists
-rwxr-xr-xupd8.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/upd8.js b/upd8.js
index 8b0c6ecc..d71e1ba9 100755
--- a/upd8.js
+++ b/upd8.js
@@ -2026,6 +2026,7 @@ writePage.html = (pageFn, {paths, strings, to}) => {
 
     theme = theme || getThemeString(wikiInfo);
 
+    banner ||= {};
     banner.classes ??= [];
     banner.src ??= '';
     banner.position ??= '';
@@ -2651,7 +2652,7 @@ function writeAlbumPage(album) {
             `--album-directory: ${album.directory}`
         ]),
 
-        banner: {
+        banner: album.bannerArtists && {
             src: to.albumBanner(album.directory),
             alt: strings('misc.alt.albumBanner'),
             position: 'top'