From f1bbe5f81bea14d3de9beaf38ee308ba96cdcb9c Mon Sep 17 00:00:00 2001 From: Monique Rio Date: Wed, 20 Nov 2024 16:18:46 +0000 Subject: [PATCH] changes get_statuses to use select --- aim/digifeeds/database/crud.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aim/digifeeds/database/crud.py b/aim/digifeeds/database/crud.py index 42410d1..dd9d45b 100644 --- a/aim/digifeeds/database/crud.py +++ b/aim/digifeeds/database/crud.py @@ -144,7 +144,7 @@ def get_statuses(db: Session): Returns: aim.digifeeds.database.models.Status: Status object """ - return db.query(models.Status).all() + return db.scalars(select(models.Status)).all() def add_item_status(db: Session, item: models.Item, status: models.Status):