hide method

void hide()

Hides the currently active indicator.

It attempts to close the SnackBar gracefully. In case of an error during closing, it clears all current SnackBars from the ScaffoldMessengerState.

Implementation

void hide() {
  try {
    _indicatorController?.close();
    _indicatorController = null;
  } catch (e) {
    _smKey.currentState?.clearSnackBars();
  }
}