Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed the minSpend condition on Discount Feature #823

Merged
merged 1 commit into from
Jan 24, 2023

Conversation

0xenm21
Copy link
Contributor

@0xenm21 0xenm21 commented Jan 24, 2023

there is an issue with the coupon code 'Minimum cart amount' if i set Minimum cart amount = 10$ && if I have cart subtotal = 100$ then this condition will not work and the coupon will not get applied.

if (! $passes || ($minSpend && $minSpend < $lines->sum('subTotal.value'))) { return $cart; }
it should be

if (! $passes || ($minSpend && $minSpend >= $lines->sum('subTotal.value'))) { return $cart; }

@vercel
Copy link

vercel bot commented Jan 24, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
lunar-docs ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Jan 24, 2023 at 11:12AM (UTC)

@alecritson alecritson merged commit f9d356a into lunarphp:main Jan 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants