Skip to content

Conversation

@MegaphoneJon
Copy link

CiviCRM now stores 9 significant digits in the currency field, which means that Simple Donate displays amounts that look like: $20.000000000.

This PR does two things:

  • Drops the numbers after the decimal point if the amount is a whole number (e.g. $20);
  • If the amount is NOT a whole number, rounds to two significant digits (e.g. $12.50).

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.

1 participant