waitFuturesAndReturnValue<V> method
Waits futures and returns value
.
Implementation
FutureOr<V> waitFuturesAndReturnValue<V>(V value) {
var futures = selectFutures();
if (futures.isEmpty) {
return value;
} else {
return Future.wait(futures).then((_) => value);
}
}