combine album name
This commit is contained in:
@@ -3,19 +3,23 @@
|
||||
import 'package:photo_manager/photo_manager.dart';
|
||||
|
||||
class BackupCandidate {
|
||||
final String albumName;
|
||||
final String id;
|
||||
final List<String> albumName;
|
||||
final AssetEntity asset;
|
||||
|
||||
BackupCandidate({
|
||||
required this.id,
|
||||
required this.albumName,
|
||||
required this.asset,
|
||||
});
|
||||
|
||||
BackupCandidate copyWith({
|
||||
String? albumName,
|
||||
String? id,
|
||||
List<String>? albumName,
|
||||
AssetEntity? asset,
|
||||
}) {
|
||||
return BackupCandidate(
|
||||
id: id ?? this.id,
|
||||
albumName: albumName ?? this.albumName,
|
||||
asset: asset ?? this.asset,
|
||||
);
|
||||
@@ -28,9 +32,11 @@ class BackupCandidate {
|
||||
bool operator ==(covariant BackupCandidate other) {
|
||||
if (identical(this, other)) return true;
|
||||
|
||||
return other.albumName == albumName && other.asset == asset;
|
||||
return other.id == id &&
|
||||
other.albumName == albumName &&
|
||||
other.asset == asset;
|
||||
}
|
||||
|
||||
@override
|
||||
int get hashCode => albumName.hashCode ^ asset.hashCode;
|
||||
int get hashCode => id.hashCode ^ albumName.hashCode ^ asset.hashCode;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user