Make all PerThing types implement all trait methods on the type (#5422)

This removes the requirement to import `PerThing` to use a type that
implements the trait.
This commit is contained in:
Bastian Köcher
2020-03-27 11:21:14 +01:00
committed by GitHub
parent acab5f0570
commit bd5758932b
8 changed files with 53 additions and 17 deletions
+1 -1
View File
@@ -19,7 +19,7 @@
//! The staking rate in NPoS is the total amount of tokens staked by nominators and validators,
//! divided by the total token supply.
use sp_runtime::{Perbill, PerThing, traits::AtLeast32Bit, curve::PiecewiseLinear};
use sp_runtime::{Perbill, traits::AtLeast32Bit, curve::PiecewiseLinear};
/// The total payout to all validators (and their nominators) per era.
///
+1 -1
View File
@@ -52,7 +52,7 @@ use super::{
EraIndex, Trait, Module, Store, BalanceOf, Exposure, Perbill, SessionInterface,
NegativeImbalanceOf, UnappliedSlash,
};
use sp_runtime::{traits::{Zero, Saturating}, PerThing, RuntimeDebug};
use sp_runtime::{traits::{Zero, Saturating}, RuntimeDebug};
use frame_support::{
StorageMap, StorageDoubleMap,
traits::{Currency, OnUnbalanced, Imbalance},