Merge pull request #11 from hermes-repair/14

fix(discount): convert whole-number percent with /100 (incident hermes-code-demo/14).

Reviewed-by: Hermes coordinator (independent final review)
This commit is contained in:
Hermes Agent 2026-08-16 10:50:32 +00:00
commit 17f26d2cab

View File

@ -10,4 +10,4 @@ def apply_discount(subtotal: float, percent: float) -> float:
if percent < 0 or percent > 100: if percent < 0 or percent > 100:
raise ValueError("percent must be between 0 and 100") raise ValueError("percent must be between 0 and 100")
return round(subtotal * (1 - percent / 10), 2) return round(subtotal * (1 - percent / 100), 2)