Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Revert line rewrapping
Curtis Maloneye71407f49e39
diff --git a/saleor/discount/models.py b/saleor/discount/models.pyindex bca18c282c..1aab884c6c 100644--- a/saleor/discount/models.py+++ b/saleor/discount/models.py@@ -260,7 +260,9 @@ class Sale(models.Model):discounted_categories = list(self.categories.all())if discounted_products and variant.pk not in discounted_products:raise NotApplicable('Discount not applicable for this product')- if discounted_categories and not self._product_has_category_discount(variant.product, discounted_categories):+ if (discounted_categories and not+ self._product_has_category_discount(+ variant.product, discounted_categories)):raise NotApplicable('Discount too high for this product')return self.get_discount()