fix(@desktop/wallet): fix wrong symbol for pegged tokens

This commit is contained in:
Dario Gabriel Lipicar 2023-01-16 17:54:51 -03:00 committed by Stefan Dunca
parent 2359dfe6a3
commit 34cf8b6533

View File

@ -53,9 +53,12 @@ QtObject:
var updateCache = true
let pegSymbol = self.tokenService.getTokenPegSymbol(symbol)
if pegSymbol != "":
var currencyFormat = self.getFiatCurrencyFormat(pegSymbol)
currencyFormat.symbol = symbol
result = currencyFormat
let currencyFormat = self.getFiatCurrencyFormat(pegSymbol)
result = CurrencyFormatDto(
symbol: symbol,
displayDecimals: currencyFormat.displayDecimals,
stripTrailingZeroes: currencyFormat.stripTrailingZeroes
)
updateCache = true
else:
let price = self.tokenService.getCachedTokenPrice(symbol, DECIMALS_CALCULATION_CURRENCY)