1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
use frame_support::{traits::Contains, weights::constants::RocksDbWeight};
use frame_system::Config;
use sp_version::RuntimeVersion;
use crate::{weights::frame_system::WeightInfo, *};
use module_transaction_pause::PausedTransactionFilter;
pub struct BaseFilter;
impl Contains<Call> for BaseFilter {
fn contains(call: &Call) -> bool {
let is_paused = PausedTransactionFilter::<Runtime>::contains(call);
if is_paused {
return false;
}
true
}
}
frame_support::parameter_types! {
pub const Version: RuntimeVersion = VERSION;
pub const SS58Prefix: u16 = 42;
}
impl Config for Runtime {
type AccountData = AccountData<Balance>;
type AccountId = AccountId;
type BaseCallFilter = BaseFilter;
type BlockHashCount = BlockHashCountForPangolin;
type BlockLength = RuntimeBlockLength;
type BlockNumber = BlockNumber;
type BlockWeights = RuntimeBlockWeights;
type Call = Call;
type DbWeight = RocksDbWeight;
type Event = Event;
type Hash = Hash;
type Hashing = Hashing;
type Header = Header;
type Index = Nonce;
type Lookup = DarwiniaAccountLookup;
type MaxConsumers = ConstU32<16>;
type OnKilledAccount = ();
type OnNewAccount = ();
type OnSetCode = ();
type Origin = Origin;
type PalletInfo = PalletInfo;
type SS58Prefix = SS58Prefix;
type SystemWeightInfo = WeightInfo<Self>;
type Version = Version;
}