unwrapOrElse method

T unwrapOrElse(
  1. T f()
)

Returns the contained Some value or computes it from a closure.

Implementation

T unwrapOrElse(T Function() f) {
  if (v == null) {
    return f();
  } else {
    return v!;
  }
}