unwrapOrNull method

T? unwrapOrNull()

Returns T on Ok, or null on Err

Implementation

T? unwrapOrNull() => switch (this) {
      Ok(:final T value) => value,
      Err() => null,
    };