TF-2536 Change the logic to get all mailbox
Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
@@ -3,21 +3,15 @@ import 'package:equatable/equatable.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/state.dart';
|
||||
import 'package:jmap_dart_client/jmap/mail/mailbox/mailbox.dart';
|
||||
|
||||
class MailboxResponse with EquatableMixin {
|
||||
final List<Mailbox>? mailboxes;
|
||||
abstract class MailboxResponse with EquatableMixin {
|
||||
final List<Mailbox> mailboxes;
|
||||
final State? state;
|
||||
|
||||
MailboxResponse({
|
||||
this.mailboxes,
|
||||
required this.mailboxes,
|
||||
this.state
|
||||
});
|
||||
|
||||
bool hasData() {
|
||||
return mailboxes != null
|
||||
&& mailboxes!.isNotEmpty
|
||||
&& state != null;
|
||||
}
|
||||
|
||||
@override
|
||||
List<Object?> get props => [mailboxes, state];
|
||||
}
|
||||
Reference in New Issue
Block a user