« get me outta code hell

generateAlbumNavLinks: don't panic when links unavailable 👻 - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-04-15 20:22:56 -0300
committer(quasar) nebula <qznebula@protonmail.com>2023-04-15 20:22:56 -0300
commita54d9ecc6177779687ac642c019dd5819187d4bf (patch)
tree28b0f7e1735dba02cc3cb824b8fc0d8cce2ee00d /src
parent0664a9bbc35a5a58999d7e5f31cb0683a0030366 (diff)
generateAlbumNavLinks: don't panic when links unavailable 👻
Diffstat (limited to 'src')
-rw-r--r--src/content/dependencies/generateAlbumNavLinks.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/content/dependencies/generateAlbumNavLinks.js b/src/content/dependencies/generateAlbumNavLinks.js
index 4ce94e1c..e4eb6c54 100644
--- a/src/content/dependencies/generateAlbumNavLinks.js
+++ b/src/content/dependencies/generateAlbumNavLinks.js
@@ -70,12 +70,12 @@ export default {
         const {content: extraLinks = []} =
           slots.showExtraLinks &&
             {content: [
-              relations.albumGalleryLink.slots({
+              relations.albumGalleryLink?.slots({
                 attributes: {class: slots.currentExtra === 'gallery' && 'current'},
                 content: language.$('albumPage.nav.gallery'),
               }),
 
-              relations.albumCommentaryLink.slots({
+              relations.albumCommentaryLink?.slots({
                 attributes: {class: slots.currentExtra === 'commentary' && 'current'},
                 content: language.$('albumPage.nav.commentary'),
               }),