update struct

This commit is contained in:
Juan Marulanda De Los Rios 2025-08-11 17:35:39 -04:00
parent 1c6d3d6920
commit b8987e6a8d

View File

@ -11,6 +11,7 @@ class GetThreadResponse {
final String from_name;
final String from_address;
final List<MailAddress> to;
final bool seen;
GetThreadResponse({
required this.id,
@ -20,6 +21,7 @@ class GetThreadResponse {
required this.from_name,
required this.from_address,
required this.to,
required this.seen,
});
factory GetThreadResponse.fromJson(Map<String, dynamic> json) {
var toList = json['to'] as List<dynamic>;
@ -32,7 +34,7 @@ class GetThreadResponse {
from_name: json['from_name'],
from_address: json['from_address'],
to: toList.map((i) => MailAddress.fromJson(i)).toList(),
);
seen: json['seen']);
}
}