clearExceptionFor static method

void clearExceptionFor(
  1. BuildContext context,
  2. Object actionOrTypeOrList, {
  3. bool notify = true,
})

Removes the given actionTypeOrList from the list of action types that failed.

Note that dispatching an action already removes that action type from the exceptions list. This removal happens as soon as the action is dispatched, not when it finishes.

actionTypeOrList can be a Type, or an Iterable of types. Any other type of object will return null and throw a StoreException after the async gap.

Widgets that use this method WILL rebuild whenever the state changes (unless you pass the notify parameter as false).

Implementation

static void clearExceptionFor(
  BuildContext context,
  Object actionOrTypeOrList, {
  bool notify = true,
}) =>
    (notify ? _getStoreWithDependency_Untyped : _getStoreNoDependency_Untyped)(context)
        .clearExceptionFor(actionOrTypeOrList);