errorOrNull property
- @useResult
The contained error if this
is an Err, or null
otherwise.
Examples
// prints "null"
print(const Ok<int, String>(2).errorOrNull);
// prints "error"
print(const Err<int, String>('error').errorOrNull);
Implementation
@useResult
E? get errorOrNull;