Unmapped catchToEffect()

From my current usage (anecdotal data) I can't seem to find a scenario where I would use catchToEffect() without map'ing the Result<Value,Error>. I wonder if it would make sense to have an overload of catchToEffect() that accepts the map closure?

Hey @eimantas, this is a good suggestion! Looking through the code base of isowords shows that pretty much every .catchToEffect() is followed by a .map.

Would you like to PR adding an overload to Effect that takes a closure for mapping? If not we can take care of it.

I would love to make a PR :)

PR is waiting for review.

One note though - I added an overload to Publisher protocol rather than Effect (next to plain catchToEffect(). Is there a reason to make an overload in Effect rather than Publisher?

Ah that was my mistake. I meant to say it should be defined on Publisher.

Thanks for the PR! Will review tomorrow :)

Terms of Service

Privacy Policy

Cookie Policy