refactor: download action (#25124)

This commit is contained in:
Jason Rasmussen
2026-01-07 17:01:20 -05:00
committed by GitHub
parent ef4aec7398
commit 4f803832ad
9 changed files with 109 additions and 103 deletions
@@ -3,7 +3,8 @@
import { getAssetControlContext } from '$lib/components/timeline/AssetSelectControlBar.svelte';
import { authManager } from '$lib/managers/auth-manager.svelte';
import { downloadArchive, downloadFile } from '$lib/utils/asset-utils';
import { handleDownloadAsset } from '$lib/services/asset.service';
import { downloadArchive } from '$lib/utils/asset-utils';
import { getAssetInfo } from '@immich/sdk';
import { IconButton } from '@immich/ui';
import { mdiDownload } from '@mdi/js';
@@ -24,7 +25,7 @@
if (assets.length === 1) {
clearSelect();
let asset = await getAssetInfo({ ...authManager.params, id: assets[0].id });
await downloadFile(asset);
await handleDownloadAsset(asset);
return;
}