Skip to content

Commit

Permalink
Merge pull request #1584 from zmcNotafraid/fix-exchange-rate
Browse files Browse the repository at this point in the history
Fix exchange rate
  • Loading branch information
zmcNotafraid committed Feb 18, 2024
2 parents 2457e55 + 6250637 commit 8af6539
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ defmodule GodwokenExplorer.ExchangeRates.Source.CoinMarketCap do
token_properties["quote"]["USD"]["price"] do
to_decimal(token_properties["quote"]["USD"]["price"])
else
1
0
end
end

Expand Down
2 changes: 1 addition & 1 deletion lib/godwoken_explorer/graphql/resolovers/udt.ex
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ defmodule GodwokenExplorer.Graphql.Resolvers.UDT do
if exchange_rate == 0 do
Decimal.new(0)
else
Decimal.new(exchange_rate)
exchange_rate
end

{:ok, %{symbol: symbol, exchange_rate: exchange_rate, timestamp: timestamp}}
Expand Down

0 comments on commit 8af6539

Please sign in to comment.