|
|
|
|
@ -8,7 +8,6 @@ import 'package:hooks_riverpod/hooks_riverpod.dart';
|
|
|
|
|
import 'package:immich_mobile/entities/asset.entity.dart';
|
|
|
|
|
import 'package:immich_mobile/entities/etag.entity.dart';
|
|
|
|
|
import 'package:immich_mobile/entities/exif_info.entity.dart';
|
|
|
|
|
import 'package:immich_mobile/entities/store.entity.dart';
|
|
|
|
|
import 'package:immich_mobile/entities/user.entity.dart';
|
|
|
|
|
import 'package:immich_mobile/models/backup/backup_candidate.model.dart';
|
|
|
|
|
import 'package:immich_mobile/providers/api.provider.dart';
|
|
|
|
|
@ -309,18 +308,6 @@ class AssetService {
|
|
|
|
|
useTimeFilter: false,
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
final duplicates = await _apiService.assetsApi.checkExistingAssets(
|
|
|
|
|
CheckExistingAssetsDto(
|
|
|
|
|
deviceAssetIds: candidates.map((c) => c.asset.id).toList(),
|
|
|
|
|
deviceId: Store.get(StoreKey.deviceId),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
if (duplicates != null) {
|
|
|
|
|
candidates
|
|
|
|
|
.removeWhere((c) => !duplicates.existingIds.contains(c.asset.id));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
await refreshRemoteAssets();
|
|
|
|
|
final remoteAssets = await _db.assets
|
|
|
|
|
.where()
|
|
|
|
|
|