diffusionkinetics / open

DiffusionKinetics open-source monorepo
MIT License
115 stars 24 forks source link

Add function for running queries as transactions #80

Closed timds closed 6 years ago

timds commented 6 years ago

I have added an mtl-style 'withTransactionC' function since postgres-simple is restricted to IO only. The function rolls back if there is an exception mid-way through the transaction. I added the safe-exceptions package to achieve this.