Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Cast max_age of cart cookie to int
Krzysztof Wolskid019b5a9cfea
diff --git a/saleor/cart/utils.py b/saleor/cart/utils.pyindex 98cce038cb..efb5f72f69 100644--- a/saleor/cart/utils.py+++ b/saleor/cart/utils.py@@ -24,7 +24,7 @@ def set_cart_cookie(simple_cart, response):# FIXME: document why session is not usedten_years = timedelta(days=(365 * 10))response.set_signed_cookie(- COOKIE_NAME, simple_cart.token, max_age=ten_years.total_seconds())+ COOKIE_NAME, simple_cart.token, max_age=int(ten_years.total_seconds()))def contains_unavailable_variants(cart):