Restructure dispatch macro related exports (#1162)

* restructure dispatch macro related exports

* moved Dispatchable to lib.rs

* fix .gitignore final newline

* ".git/.scripts/commands/fmt/fmt.sh"

* fix rustdocs

* wip

---------

Co-authored-by: Liam Aharon <liam.aharon@hotmail.com>
Co-authored-by: command-bot <>
Co-authored-by: ordian <write@reusable.software>
This commit is contained in:
Juan
2023-08-31 13:08:44 +02:00
committed by GitHub
parent d6af073aa5
commit bdbe982970
84 changed files with 195 additions and 244 deletions
+10 -3
View File
@@ -28,7 +28,7 @@
#![cfg_attr(not(feature = "std"), no_std)]
use frame_support::{
dispatch::{DispatchError, DispatchResult},
dispatch::DispatchResult,
ensure,
traits::{
fungible, Currency, Get, LockIdentifier, LockableCurrency, PollStatus, Polling,
@@ -38,7 +38,7 @@ use frame_support::{
use frame_system::pallet_prelude::BlockNumberFor;
use sp_runtime::{
traits::{AtLeast32BitUnsigned, Saturating, StaticLookup, Zero},
ArithmeticError, Perbill,
ArithmeticError, DispatchError, Perbill,
};
use sp_std::prelude::*;
@@ -86,8 +86,15 @@ type ClassOf<T, I = ()> = <<T as Config<I>>::Polls as Polling<TallyOf<T, I>>>::C
#[frame_support::pallet]
pub mod pallet {
use super::*;
use frame_support::{pallet_prelude::*, traits::ClassCountOf};
use frame_support::{
pallet_prelude::{
DispatchResultWithPostInfo, IsType, StorageDoubleMap, StorageMap, ValueQuery,
},
traits::ClassCountOf,
Twox64Concat,
};
use frame_system::pallet_prelude::*;
use sp_runtime::BoundedVec;
#[pallet::pallet]
pub struct Pallet<T, I = ()>(_);