Files
MaggsVictoryVoyage/lib/models/feed_item.dart
2023-10-20 21:13:49 +02:00

17 lines
344 B
Dart

class FeedItem {
final String text;
final DateTime timestamp;
FeedItem.fromMap(Map<String, dynamic> map)
: text = map['text'],
timestamp = DateTime.parse(map['timestamp']);
@override
bool operator ==(Object other) {
if (other is FeedItem) {
return other.timestamp == timestamp;
}
return false;
}
}