From fe4f7982e793002e21bd50857839940bd0b7c69e Mon Sep 17 00:00:00 2001 From: Miles Zhang Date: Thu, 4 Jan 2024 23:42:41 +0800 Subject: [PATCH] fix: exchange_rate should be decimal Signed-off-by: Miles Zhang --- lib/godwoken_explorer/graphql/resolovers/udt.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/godwoken_explorer/graphql/resolovers/udt.ex b/lib/godwoken_explorer/graphql/resolovers/udt.ex index 104bc8ee..d3a67898 100644 --- a/lib/godwoken_explorer/graphql/resolovers/udt.ex +++ b/lib/godwoken_explorer/graphql/resolovers/udt.ex @@ -86,7 +86,7 @@ defmodule GodwokenExplorer.Graphql.Resolvers.UDT do if exchange_rate == 0 do Decimal.new(0) else - exchange_rate + Decimal.new(exchange_rate) end {:ok, %{symbol: symbol, exchange_rate: exchange_rate, timestamp: timestamp}}