mirror of
https://github.com/immich-app/immich.git
synced 2026-06-22 14:52:17 -07:00
chore(mobile): drop unused stack getAll
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import 'package:drift/drift.dart';
|
||||
import 'package:immich_mobile/domain/models/stack.model.dart';
|
||||
import 'package:immich_mobile/infrastructure/entities/stack.entity.drift.dart';
|
||||
import 'package:immich_mobile/infrastructure/repositories/db.repository.dart';
|
||||
|
||||
@@ -23,14 +22,6 @@ class DriftStackRepository extends DriftDatabaseRepository {
|
||||
final Drift _db;
|
||||
const DriftStackRepository(this._db) : super(_db);
|
||||
|
||||
Future<List<Stack>> getAll(String userId) {
|
||||
final query = _db.stackEntity.select()..where((e) => e.ownerId.equals(userId));
|
||||
|
||||
return query.map((stack) {
|
||||
return stack.toDto();
|
||||
}).get();
|
||||
}
|
||||
|
||||
// Find stacks whose primary should flip back after a revert: a local that was
|
||||
// uploaded as an edit (prior in the stack) now hashes to a DIFFERENT member
|
||||
// that isn't the primary. Two discriminators keep this from fighting stacks
|
||||
@@ -163,9 +154,3 @@ class DriftStackRepository extends DriftDatabaseRepository {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
extension on StackEntityData {
|
||||
Stack toDto() {
|
||||
return Stack(id: id, createdAt: createdAt, updatedAt: updatedAt, ownerId: ownerId, primaryAssetId: primaryAssetId);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user