File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
returns/_internal/pipeline Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ See [0Ver](https://0ver.org/).
1212
1313- Makes ` _Nothing ` a singleton
1414- Fixes typos in documentation
15-
15+ - Refactor ` flow ` function
1616
1717## 0.15.0 aka The initial HKT release
1818
Original file line number Diff line number Diff line change 11from functools import reduce
22from typing import TypeVar
33
4- from returns .functions import compose
54
65_InstanceType = TypeVar ('_InstanceType' )
76_PipelineStepType = TypeVar ('_PipelineStepType' )
@@ -49,4 +48,8 @@ def flow(
4948
5049 Requires our :ref:`mypy plugin <mypy-plugins>`.
5150 """
52- return reduce (compose , functions )(instance ) # type: ignore
51+ return reduce ( # type: ignore
52+ lambda composed , function : function (composed ),
53+ functions ,
54+ instance ,
55+ )
You can’t perform that action at this time.
0 commit comments