diff --git a/pallets/liquidity-mining/rpc/src/lib.rs b/pallets/liquidity-mining/rpc/src/lib.rs index 45e1d6742..4767c59cf 100644 --- a/pallets/liquidity-mining/rpc/src/lib.rs +++ b/pallets/liquidity-mining/rpc/src/lib.rs @@ -28,7 +28,7 @@ use node_primitives::{Balance, CurrencyId}; use sp_api::ProvideRuntimeApi; use sp_blockchain::HeaderBackend; use sp_rpc::number::NumberOrHex; -use sp_runtime::{generic::BlockId, traits::Block as BlockT, SaturatedConversion}; +use sp_runtime::{generic::BlockId, traits::Block as BlockT}; #[rpc] pub trait LiquidityMiningRpcApi { @@ -77,7 +77,7 @@ where match rs { Ok(rewards) => Ok(rewards .into_iter() - .map(|(token, amount)| (token, NumberOrHex::Number(amount.saturated_into()))) + .map(|(token, amount)| (token, NumberOrHex::Hex(amount.into()))) .collect()), Err(e) => Err(RpcError { code: ErrorCode::InternalError,