mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
chore: remove main timeline query watch throttle (#21942)
This commit is contained in:
parent
71e33e35dc
commit
0166e99d90
1 changed files with 4 additions and 8 deletions
|
|
@ -42,14 +42,10 @@ class DriftTimelineRepository extends DriftDatabaseRepository {
|
|||
throw UnsupportedError("GroupAssetsBy.none is not supported for watchMainBucket");
|
||||
}
|
||||
|
||||
return _db.mergedAssetDrift
|
||||
.mergedBucket(userIds: userIds, groupBy: groupBy.index)
|
||||
.map((row) {
|
||||
final date = row.bucketDate.dateFmt(groupBy);
|
||||
return TimeBucket(date: date, assetCount: row.assetCount);
|
||||
})
|
||||
.watch()
|
||||
.throttle(const Duration(seconds: 3), trailing: true);
|
||||
return _db.mergedAssetDrift.mergedBucket(userIds: userIds, groupBy: groupBy.index).map((row) {
|
||||
final date = row.bucketDate.dateFmt(groupBy);
|
||||
return TimeBucket(date: date, assetCount: row.assetCount);
|
||||
}).watch();
|
||||
}
|
||||
|
||||
Future<List<BaseAsset>> _getMainBucketAssets(List<String> userIds, {required int offset, required int count}) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue