deleteMessages method Null safety

Future<DeleteResult> deleteMessages(
  1. MessageSequence sequence

Deletes the given message sequence.

Depending on the service capabalities either the sequence is moved to the trash, copied to the trash or just flagged as deleted. Returns a DeleteResult that can be used for an undo operation, compare undoDeleteMessages.


Future<DeleteResult> deleteMessages(MessageSequence sequence) {
  final trashMailbox = getMailbox(MailboxFlag.trash);
  return _incomingMailClient.deleteMessages(sequence, trashMailbox);