Skip to content

High performance self-hosted photo and video management solution.

fix(web): bypass the onStackAssets shortcut when only one is selected (#8559)

Guillermoa2e38270e465
diff --git a/web/src/lib/components/photos-page/asset-grid.svelte b/web/src/lib/components/photos-page/asset-grid.svelte
index 9aca51fa00..c8ca6b17a6 100644
--- a/web/src/lib/components/photos-page/asset-grid.svelte
+++ b/web/src/lib/components/photos-page/asset-grid.svelte
@@ -87,10 +87,12 @@
};
const onStackAssets = async () => {
- await stackAssets(Array.from($selectedAssets), (ids) => {
- assetStore.removeAssets(ids);
- dispatch('escape');
- });
+ if ($selectedAssets.size > 1) {
+ await stackAssets(Array.from($selectedAssets), (ids) => {
+ assetStore.removeAssets(ids);
+ dispatch('escape');
+ });
+ }
};
$: shortcutList = (() => {