lastOr method

T? lastOr([
  1. T? ifEmpty
])

Implementation

T? lastOr([T? ifEmpty]) {
  if (this.isEmpty) return ifEmpty;
  return this.last;
}