You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 7, 2023. It is now read-only.
Hey. Today I sat down to study your api. So there was a small problem in the example line: BigDecimal BTCToUSD = exchange.toFiat("USD", new BigDecimal(100000000)); - throw
java.lang.NumberFormatException
at java.math.BigDecimal.(BigDecimal.java:494)
at java.math.BigDecimal.(BigDecimal.java:383)
at java.math.BigDecimal.(BigDecimal.java:806)
at info.blockchain.api.exchangerates.ExchangeRates.toFiat(ExchangeRates.java:96)
I ran the code in debug mode and found that in the line return new BigDecimal(response);
in ExchangeRates().toFiat() in response, the value is returned in the following form: 819,060,000,000. I'm not a very experienced developer, but it seems to me that BigDecimal can not process commas in this sense. I will be glad to any answer. Thank you and sorry for my english)
The text was updated successfully, but these errors were encountered:
Hey. Today I sat down to study your api. So there was a small problem in the example line:
BigDecimal BTCToUSD = exchange.toFiat("USD", new BigDecimal(100000000));
- throwjava.lang.NumberFormatException
at java.math.BigDecimal.(BigDecimal.java:494)
at java.math.BigDecimal.(BigDecimal.java:383)
at java.math.BigDecimal.(BigDecimal.java:806)
at info.blockchain.api.exchangerates.ExchangeRates.toFiat(ExchangeRates.java:96)
I ran the code in debug mode and found that in the line
return new BigDecimal(response);
in ExchangeRates().toFiat() in response, the value is returned in the following form: 819,060,000,000. I'm not a very experienced developer, but it seems to me that BigDecimal can not process commas in this sense. I will be glad to any answer. Thank you and sorry for my english)
The text was updated successfully, but these errors were encountered: