stopPollingIfNeeded method Null safety

Future<void> stopPollingIfNeeded()

Stops listening for new messages if this client is currently polling.

Implementation

Future<void> stopPollingIfNeeded() {
  if (_incomingMailClient.isPolling()) {
    return _incomingMailClient.stopPolling();
  }
  return Future.value();
}