mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 14:01:02 +00:00
Refactored Slicable (#324)
* Refactored Slicable * Docs * Wasm build * Wasm build * Renamed traits * Review nits * Renamed Slicable as well
This commit is contained in:
committed by
Gav Wood
parent
e1c90b573b
commit
1e1ddf61f2
@@ -43,7 +43,7 @@ pub mod chain_spec;
|
||||
use std::sync::Arc;
|
||||
use std::collections::HashMap;
|
||||
|
||||
use codec::Slicable;
|
||||
use codec::Encode;
|
||||
use transaction_pool::TransactionPool;
|
||||
use polkadot_api::{PolkadotApi, light::RemotePolkadotApiWrapper};
|
||||
use polkadot_primitives::{Block, BlockId, Hash};
|
||||
@@ -265,7 +265,7 @@ impl<B, E, A> network::TransactionPool<Block> for TransactionPoolAdapter<B, E, A
|
||||
}
|
||||
|
||||
let encoded = transaction.encode();
|
||||
if let Some(uxt) = codec::Slicable::decode(&mut &encoded[..]) {
|
||||
if let Some(uxt) = codec::Decode::decode(&mut &encoded[..]) {
|
||||
let best_block_id = self.best_block_id()?;
|
||||
match self.pool.import_unchecked_extrinsic(best_block_id, uxt) {
|
||||
Ok(xt) => Some(*xt.hash()),
|
||||
|
||||
Reference in New Issue
Block a user