Skip to content

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

Fix resolve_stock filter (country)

Piotr Antosz2e8c3de80bec
diff --git a/saleor/graphql/product/types/products.py b/saleor/graphql/product/types/products.py
index 2c847a8eea..f6c0f543f3 100644
--- a/saleor/graphql/product/types/products.py
+++ b/saleor/graphql/product/types/products.py
@@ -292,7 +292,7 @@ class ProductVariant(CountableDjangoObjectType, MetadataObjectType):
root.stock.annotate_available_quantity().all(), info
)
return gql_optimizer.query(
- root.stock.annotate_available_quantity().for_country("country").all(), info
+ root.stock.annotate_available_quantity().for_country(country).all(), info
)
@staticmethod