noqa the x == False for sqlalchemy

This commit is contained in:
Kenneth Kehl
2024-12-19 11:36:50 -08:00
parent 83193c221a
commit db16f94afb
2 changed files with 29 additions and 16 deletions
+5 -2
View File
@@ -57,7 +57,7 @@ class PermissionDAO(DAOClass):
select(self.Meta.model)
.where(self.Meta.model.user_id == user_id)
.join(Permission.service)
.where(Permission.active == True) # noqa
.where(Permission.service.active == True) # noqa
)
.scalars()
.all()
@@ -69,7 +69,10 @@ class PermissionDAO(DAOClass):
select(self.Meta.model)
.where(self.Meta.model.user_id == user_id)
.join(Permission.service)
.where(Permission.active == True, Permission.id == service_id) # noqa
.where(
Permission.service.active == True, # noqa
Permission.service.id == service_id,
) # noqa
)
.scalars()
.all()