Skip to content

Commit

Permalink
(#357) A better fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ForNeVeR committed Jul 10, 2023
1 parent cf48796 commit c240afc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rd-net/Lifetimes/Collections/Viewable/ReactiveEx.cs
Original file line number Diff line number Diff line change
Expand Up @@ -374,10 +374,10 @@ public MappedProperty(IViewableProperty<T> source, Func<T, R> map)
{
mySource = source;
myMap = map;
Change = new MappedSink<T, R>(source, myMap);
Change = new MappedSink<T, R>(source.Change, myMap);
}

public void Advise(Lifetime lifetime, Action<R> handler) => Change.Advise(lifetime, handler);
public void Advise(Lifetime lifetime, Action<R> handler) => mySource.Advise(lifetime, v => handler(myMap(v)));

public ISource<R> Change { get; }

Expand Down

0 comments on commit c240afc

Please sign in to comment.