Skip to content

Commit

Permalink
Fix null annotation in "Subject"
Browse files Browse the repository at this point in the history
  • Loading branch information
atifaziz committed Nov 16, 2022
1 parent c6ca90d commit d5f066c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions MoreLinq/Reactive/Subject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -116,12 +116,12 @@ public void OnNext(T value)
}

public void OnError(Exception error) =>
OnFinality(ref _error, error, (observer, err) => observer.OnError(err!));
OnFinality(ref _error, error, (observer, err) => observer.OnError(err));

public void OnCompleted() =>
OnFinality(ref _completed, true, (observer, _) => observer.OnCompleted());

void OnFinality<TState>(ref TState state, TState value, Action<IObserver<T>, TState> action)
void OnFinality<TState>(ref TState? state, TState value, Action<IObserver<T>, TState> action)
{
if (IsMuted)
return;
Expand Down

0 comments on commit d5f066c

Please sign in to comment.