Simplify return from withResource in Main.hs

This commit is contained in:
Diogo Biazus
2016-02-20 18:03:17 -08:00
committed by Joe Nelson
parent de848f64fa
commit 01ab540ffe
+1 -1
View File
@@ -101,5 +101,5 @@ main = do
Left err -> return $ errResponse HT.status500 (cs . show $ err)
Right c -> do
resOrError <- handleReq c
either (return . pgErrResponse) return resOrError
return $ either pgErrResponse id resOrError
respond res