checked<R> method

FutureOr<R> checked<R>(
  1. R fn()
)

Executes a function if the full data set is loaded, otherwise, returns a future

Implementation

FutureOr<R> checked<R>(R fn()) {
  if (_values.isFirstResolved) {
    return fn();
  } else {
    return _reloadCompletions.stream.first.then((_) => fn());
  }
}