From 68eab91db8f4a19556e0f8c61e051aceccf12fe3 Mon Sep 17 00:00:00 2001 From: Yonle Date: Fri, 27 Feb 2026 22:14:01 +0700 Subject: [PATCH] gallery: use Set on displaytypes instead --- src/components/gallery/gallery.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/gallery/gallery.js b/src/components/gallery/gallery.js index 849000429..19d568b3a 100644 --- a/src/components/gallery/gallery.js +++ b/src/components/gallery/gallery.js @@ -4,7 +4,7 @@ import Attachment from '../attachment/attachment.vue' import { useMediaViewerStore } from 'src/stores/media_viewer.js' -const displayTypes = ["image", "video", "flash"] +const displayTypes = new Set(["image", "video", "flash"]) const Gallery = { props: [ @@ -54,7 +54,7 @@ const Gallery = { { items: [] }, ] } - if (!displayTypes.includes(attachment.type)) { + if (!displayTypes.has(attachment.type)) { return [ ...acc, { minimal: true, items: [attachment] },