mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 22:11:02 +00:00
override conversion rate in estimate-message-fee RPC (#1189)
This commit is contained in:
committed by
Bastian Köcher
parent
22b1e456ab
commit
741484214e
@@ -53,7 +53,7 @@ use sp_runtime::{
|
||||
create_runtime_str, generic, impl_opaque_keys,
|
||||
traits::{AccountIdLookup, Block as BlockT, Keccak256, NumberFor, OpaqueKeys},
|
||||
transaction_validity::{TransactionSource, TransactionValidity},
|
||||
ApplyExtrinsicResult, FixedPointNumber, MultiSignature, MultiSigner, Perquintill,
|
||||
ApplyExtrinsicResult, FixedPointNumber, FixedU128, MultiSignature, MultiSigner, Perquintill,
|
||||
};
|
||||
use sp_std::{collections::btree_map::BTreeMap, prelude::*};
|
||||
#[cfg(feature = "std")]
|
||||
@@ -892,10 +892,12 @@ impl_runtime_apis! {
|
||||
fn estimate_message_delivery_and_dispatch_fee(
|
||||
_lane_id: bp_messages::LaneId,
|
||||
payload: ToMillauMessagePayload,
|
||||
millau_to_this_conversion_rate: Option<FixedU128>,
|
||||
) -> Option<Balance> {
|
||||
estimate_message_dispatch_and_delivery_fee::<WithMillauMessageBridge>(
|
||||
&payload,
|
||||
WithMillauMessageBridge::RELAYER_FEE_PERCENT,
|
||||
millau_to_this_conversion_rate,
|
||||
).ok()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user