takeUnless method
Returns the receiver if non-null and does NOT satisfy predicate, otherwise null.
Implementation
T? takeUnless(bool Function(T it) predicate) {
final value = this;
if (value == null) return null;
return !predicate(value) ? value : null;
}