Closed racitup closed 6 years ago
I added the possibility to use more than 2 decimals and set the previous hardcoded default (2) as a limitation because I was not comfortable with changing the old behaviour without adding unit test with a specific example.
Would this mean that currencies should also store their default rounding?
Very sensible! I've fixed this issue in the above PR. If you also look at my django-shop branch, the money types automatically use the exponent from the currency iso source stored in the info column.. so in a way they are already stored!
Merged and fixed.
On review of utils.py it appears that the
price_rounding
function requires decimals >=2. Currencies such as JPY don't have a decimal (==0).