fix: handle missing assets gracefully

This commit is contained in:
shenlong-tanwen
2025-07-23 19:24:29 +05:30
parent 05d26dc683
commit 19c9f932ea
4 changed files with 23 additions and 17 deletions
@@ -112,8 +112,9 @@ class _BulkSelectIconButton extends ConsumerWidget {
List<BaseAsset> bucketAssets;
try {
bucketAssets = ref
.watch(timelineServiceProvider)
.getAssets(assetOffset, bucket.assetCount);
.watch(timelineServiceProvider)
.getAssets(assetOffset, bucket.assetCount) ??
[];
} catch (e) {
bucketAssets = <BaseAsset>[];
}