Don't flush errors when checking zero priced order validity

This commit is contained in:
Matt-Yorkley
2023-07-04 14:42:31 +01:00
parent 66a546027f
commit 671dfc7082

View File

@@ -222,7 +222,7 @@ module Spree
# There are items present in the order, but either the items have zero price,
# or the order's total has been modified (maybe discounted) to zero.
def zero_priced_order?
valid? && line_items.count.positive? && total.zero?
dup.valid? && line_items.count.positive? && total.zero?
end
# Returns the relevant zone (if any) to be used for taxation purposes.