Багфикс

This commit is contained in:
urec56 2024-08-20 14:43:16 +04:00
parent 39bebabcd6
commit c3abcab6bc

View file

@ -24,9 +24,10 @@ class UnitOfWork:
await self.rollback() await self.rollback()
await self.session.close() await self.session.close()
except SQLAlchemyError: except SQLAlchemyError:
raise BlackPhoenixException pass
if isinstance(exc, SQLAlchemyError): # raise BlackPhoenixException
raise BlackPhoenixException # if isinstance(exc, SQLAlchemyError):
# raise BlackPhoenixException
async def commit(self): async def commit(self):
await self.session.commit() await self.session.commit()