stopListening method

Future stopListening()

Cancel the StreamSubscription and stop listening.

Implementation

Future stopListening() async {
  if (_subscription != null) {
    await _subscription!.cancel();
  }
}