Update Substrate & Polkadot (#41)

This commit is contained in:
Bastian Köcher
2020-01-16 17:26:49 +01:00
committed by GitHub
parent 9f7d5c1ea4
commit 73bcef09ab
3 changed files with 552 additions and 515 deletions
+547 -512
View File
File diff suppressed because it is too large Load Diff
@@ -59,6 +59,7 @@ fn call_validate_block(
&mut ext_ext,
&WASM_BINARY,
1024,
false,
)
.map(|v| ValidationResult::decode(&mut &v[..]).expect("Decode `ValidationResult`."))
.map(|v| Header::decode(&mut &v.head_data[..]).expect("Decode `Header`."))
+4 -3
View File
@@ -25,7 +25,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
use sp_api::impl_runtime_apis;
use sp_core::OpaqueMetadata;
use sp_runtime::traits::{
BlakeTwo256, Block as BlockT, ConvertInto, NumberFor, StaticLookup, Verify,
BlakeTwo256, Block as BlockT, ConvertInto, StaticLookup, Verify,
};
use sp_runtime::{
create_runtime_str, generic, impl_opaque_keys, transaction_validity::TransactionValidity,
@@ -216,6 +216,7 @@ impl pallet_balances::Trait for Runtime {
type ExistentialDeposit = ExistentialDeposit;
type TransferFee = TransferFee;
type CreationFee = CreationFee;
type OnReapAccount = System;
}
impl pallet_transaction_payment::Trait for Runtime {
@@ -331,8 +332,8 @@ impl_runtime_apis! {
}
impl sp_offchain::OffchainWorkerApi<Block> for Runtime {
fn offchain_worker(number: NumberFor<Block>) {
Executive::offchain_worker(number)
fn offchain_worker(header: &<Block as BlockT>::Header) {
Executive::offchain_worker(header)
}
}