mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 03:27:58 +00:00
Weights to u64 + Balances Weights (#5446)
Co-Authored-By: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
|
||||
use sp_runtime::{generic, traits::{BlakeTwo256, Block as _, Verify}, DispatchError};
|
||||
use sp_core::{H256, sr25519};
|
||||
use frame_support::weights::{SimpleDispatchInfo, MINIMUM_WEIGHT};
|
||||
|
||||
mod system;
|
||||
|
||||
@@ -32,7 +33,7 @@ mod module1 {
|
||||
pub struct Module<T: Trait<I>, I: Instance = DefaultInstance> for enum Call
|
||||
where origin: <T as system::Trait>::Origin
|
||||
{
|
||||
#[weight = frame_support::weights::SimpleDispatchInfo::default()]
|
||||
#[weight = SimpleDispatchInfo::FixedNormal(MINIMUM_WEIGHT)]
|
||||
pub fn fail(_origin) -> frame_support::dispatch::DispatchResult {
|
||||
Err(Error::<T, I>::Something.into())
|
||||
}
|
||||
@@ -59,7 +60,7 @@ mod module2 {
|
||||
pub struct Module<T: Trait> for enum Call
|
||||
where origin: <T as system::Trait>::Origin
|
||||
{
|
||||
#[weight = frame_support::weights::SimpleDispatchInfo::default()]
|
||||
#[weight = SimpleDispatchInfo::FixedNormal(MINIMUM_WEIGHT)]
|
||||
pub fn fail(_origin) -> frame_support::dispatch::DispatchResult {
|
||||
Err(Error::<T>::Something.into())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user