clearError method

void clearError()

Clears the current error message.

Sets the error to an empty string and notifies listeners.

Implementation

void clearError() {
  _error = '';
  notifyListeners();
}