copyWith method
Implementation
EntityState copyWith({
bool? isFetching,
DateTime? lastFetched,
String? error,
bool? stale,
bool clearError = false,
}) => EntityState(
isFetching: isFetching ?? this.isFetching,
lastFetched: lastFetched ?? this.lastFetched,
error: clearError ? null : (error ?? this.error),
stale: stale ?? this.stale,
);