Skip to content

Commit

Permalink
Added '_innerSerialDisposable?.Dispose()' call when _innerSerialDispo…
Browse files Browse the repository at this point in the history
…sable changes. (#15998)
  • Loading branch information
ds1709 authored Jun 13, 2024
1 parent 86d6043 commit 05f431b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Avalonia.Base/Reactive/Operators/Switch.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ public override void OnNext(IObservable<TSource> value)

var innerObserver = new InnerObserver(this, id);

_innerSerialDisposable?.Dispose();
_innerSerialDisposable = innerObserver;
innerObserver.Disposable = value.Subscribe(innerObserver);
}
Expand Down

0 comments on commit 05f431b

Please sign in to comment.