fix display name of non-fiat traditional currencies

This commit is contained in:
woodser 2025-06-07 08:02:21 -04:00
parent 285335d138
commit 48585db8f0
No known key found for this signature in database
GPG key ID: 55A10DD48ADEE5EF

View file

@ -406,6 +406,13 @@ public class CurrencyUtil {
removedCryptoCurrency.isPresent() ? removedCryptoCurrency.get().getName() : Res.get("shared.na");
return getCryptoCurrency(currencyCode).map(TradeCurrency::getName).orElse(xmrOrRemovedAsset);
}
if (isTraditionalNonFiatCurrency(currencyCode)) {
return getTraditionalNonFiatCurrencies().stream()
.filter(currency -> currency.getCode().equals(currencyCode))
.findAny()
.map(TradeCurrency::getName)
.orElse(currencyCode);
}
try {
return Currency.getInstance(currencyCode).getDisplayName();
} catch (Throwable t) {