mapError

Map error to a new type or return encapsulated value.

Return

new expected with transformed error or encapsulated value

Parameters

errorFun

Function handling the case when error is present.