Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Change OrderConfirm lines count() to exists()

Tomasz Szymanskia9b6fc85a62e
diff --git a/saleor/graphql/order/mutations/orders.py b/saleor/graphql/order/mutations/orders.py
index 16cba42aab..d176c96588 100644
--- a/saleor/graphql/order/mutations/orders.py
+++ b/saleor/graphql/order/mutations/orders.py
@@ -583,7 +583,7 @@ class OrderConfirm(ModelMutation):
)
}
)
- if not instance.lines.count():
+ if not instance.lines.exists():
raise ValidationError(
{
"id": ValidationError(