recyclePoolElement method

FutureOr<C?> recyclePoolElement(
  1. C o
)
inherited

Implementation

FutureOr<O?> recyclePoolElement(O o) {
  var valid = isPoolElementValid(o);

  if (valid is Future<bool>) {
    return valid.then((valid) => valid ? o : null);
  }

  return valid ? o : null;
}