core: handle all DB errors (#763)
This commit is contained in:
committed by
GitHub
parent
815981487b
commit
96866c7a5d
@@ -2247,7 +2247,7 @@ withStore action = do
|
||||
liftEitherError ChatErrorStore $
|
||||
withTransaction st (runExceptT . action) `E.catch` handleInternal
|
||||
where
|
||||
handleInternal :: DB.SQLError -> IO (Either StoreError a)
|
||||
handleInternal :: E.SomeException -> IO (Either StoreError a)
|
||||
handleInternal = pure . Left . SEInternalError . show
|
||||
|
||||
chatCommandP :: Parser ChatCommand
|
||||
|
||||
Reference in New Issue
Block a user