-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Description
In my snap code I am threading EitherT (I probably should be threading Control.Error instead) through my code to handle failure gracefully in my Snap handlers. As such I have found the need for such helper functions as these: https://bitbucket.org/robertmassaioli/hackathon/src/2badb4f29792ff3aaba45fc3523f14d6345fbe0c/src/PostgresqlHelpers.hs
The main change here is that returning a Left will result in a rollback of the transaction; which I think is excellent behaviour when you think of all lefts as errors.
Do you think that they would make a good addition to this codebase? Or maybe an equivalent for ErrorT might be cool; since ErrorT is a better monad transformer to use for this use case.
Metadata
Metadata
Assignees
Labels
No labels