vkhorikov / CSharpFunctionalExtensions

Functional extensions for C#

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add overload for passing object when Result is Failure

pantonis opened this issue · comments

Sometimes during the Result.Failure check we need to have the resulting object for further processing in addition to the error. Is it possible to add it as an overload?

The concept for Result is that it should either be successful and contain a value, or unsuccessful and not contain a value. For your case, I recommend introducing a custom class.