getOrNull method

T? getOrNull()

Returns the value if this is a Result.success or null otherwise.

Implementation

T? getOrNull() => fold((_) => null, (value) => value);