Fixed movie page broken due missing chapters property.

This commit is contained in:
DebaucheryLibrarian 2024-10-25 02:43:04 +02:00
parent 3e6ad72416
commit 831f92683e
1 changed files with 2 additions and 2 deletions

View File

@ -51,10 +51,10 @@
<div
v-if="release.photos.length > 0 || release.caps.length > 0 || release.chapters.some((chapter) => chapter.poster) || coversInAlbum"
class="album"
:class="{ single: (release.photos.length + release.caps.length + release.chapters.filter((chapter) => chapter.poster).length) === 1 }"
:class="{ single: (release.photos.length + release.caps.length + (release.chapters?.filter((chapter) => chapter.poster).length || 0)) === 1 }"
>
<div
v-for="photo in [...(coversInAlbum ? release.covers : []), ...release.photos, ...release.caps, ...release.chapters.map((chapter) => chapter.poster).filter(Boolean)]"
v-for="photo in [...(coversInAlbum ? release.covers : []), ...release.photos, ...release.caps, ...(release.chapters?.map((chapter) => chapter.poster).filter(Boolean) || [])]"
:key="`photo-${photo.id}`"
class="photo-container"
>