fetchNextPage method Null safety

Future<List<MimeMessage>> fetchNextPage(
  1. PagedMessageResult pagedResult
)

Retrieves the next page of messages for the specified pagedResult.

Implementation

Future<List<MimeMessage>> fetchNextPage(
    PagedMessageResult pagedResult) async {
  final messages = await fetchMessagesNextPage(pagedResult.pagedSequence,
      fetchPreference: pagedResult.fetchPreference);
  pagedResult.insertAll(messages);
  return messages;
}