firstOrNull property
T?
get
firstOrNull
Returns the first element in the set, or null if the set is empty.
Implementation
T? get firstOrNull => isNotEmpty ? value.first : null;
Returns the first element in the set, or null if the set is empty.
T? get firstOrNull => isNotEmpty ? value.first : null;