Skip to content

Commit 8665fe0

Browse files
committed
More idiomatic ReaderT transformation
1 parent f1660eb commit 8665fe0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,9 @@ hoistReaderT ::
6060
forall props state action env m.
6161
HaloM props state action (ReaderT env m) ~>
6262
ReaderT env (HaloM props state action m)
63-
hoistReaderT x = ReaderT \env -> Halo.hoist (flip runReaderT env) x
63+
hoistReaderT x = do
64+
env <- ask
65+
lift (Halo.hoist (flip runReaderT env) x)
6466
```
6567

6668
### Working with props

0 commit comments

Comments
 (0)