Skip to content

Comments

fix: wrong currency code returned from fiatCurrencyString#477

Merged
pankcuf merged 1 commit intodashpay:developfrom
Syn-McJ:fix/fiat-formatting
Jan 6, 2023
Merged

fix: wrong currency code returned from fiatCurrencyString#477
pankcuf merged 1 commit intodashpay:developfrom
Syn-McJ:fix/fiat-formatting

Conversation

@Syn-McJ
Copy link
Member

@Syn-McJ Syn-McJ commented Jan 6, 2023

Issue being fixed or feature implemented

When fiatCurrencyString is called with a custom currency code, the returned amount is calculated correctly but the currency code is wrong - it is set to the local currency code.

What was done?

To format the currency correctly, the localFormat.currencyCode is changed before formatting and then restored to the original value.

How Has This Been Tested?

manually

Breaking Changes

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

@Syn-McJ Syn-McJ requested review from pankcuf and tikhop January 6, 2023 07:58
@Syn-McJ Syn-McJ self-assigned this Jan 6, 2023
@pankcuf pankcuf merged commit 2938ff8 into dashpay:develop Jan 6, 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.

2 participants