Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1008,7 +1008,7 @@ def checkout():
|
|
| 1008 |
try:
|
| 1009 |
# Fetch the selected coupon (if any)
|
| 1010 |
data = request.json
|
| 1011 |
-
selected_coupon = data.get("selectedCoupon", "").strip()
|
| 1012 |
print(f"Selected Coupon: {selected_coupon}") # Debugging selected coupon
|
| 1013 |
|
| 1014 |
# Fetch cart items for the current user
|
|
|
|
| 1008 |
try:
|
| 1009 |
# Fetch the selected coupon (if any)
|
| 1010 |
data = request.json
|
| 1011 |
+
selected_coupon = data.get("selectedCoupon", "").strip() if data.get("selectedCoupon") else None
|
| 1012 |
print(f"Selected Coupon: {selected_coupon}") # Debugging selected coupon
|
| 1013 |
|
| 1014 |
# Fetch cart items for the current user
|