mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 16:21:02 +00:00
Mandate weight annotation (#5357)
* Disallow default weight * Fix build and test * Fix tests * Fix another beloved ui test. * fix beloved trybuild tests * fix treasury? * Final test fix * Fix build * Fix another one * Fix * More doctest fix
This commit is contained in:
@@ -35,12 +35,13 @@
|
||||
//! ### Example - Get random seed for the current block
|
||||
//!
|
||||
//! ```
|
||||
//! use frame_support::{decl_module, dispatch, traits::Randomness};
|
||||
//! use frame_support::{decl_module, dispatch, traits::Randomness, weights::SimpleDispatchInfo};
|
||||
//!
|
||||
//! pub trait Trait: frame_system::Trait {}
|
||||
//!
|
||||
//! decl_module! {
|
||||
//! pub struct Module<T: Trait> for enum Call where origin: T::Origin {
|
||||
//! #[weight = SimpleDispatchInfo::default()]
|
||||
//! pub fn random_module_example(origin) -> dispatch::DispatchResult {
|
||||
//! let _random_seed = <pallet_randomness_collective_flip::Module<T>>::random_seed();
|
||||
//! Ok(())
|
||||
|
||||
Reference in New Issue
Block a user