Skip to content
Snippets Groups Projects
Commit 87093fee authored by thiolliere's avatar thiolliere Committed by GitHub
Browse files

Fix inconsistent head_data (#18)


* fix

* Update consensus/src/lib.rs

Co-Authored-By: default avatarBastian Köcher <bkchr@users.noreply.github.com>
parent 28ec1f31
No related merge requests found
......@@ -96,10 +96,9 @@ pub fn follow_polkadot<'a, L: 'a, P: 'a>(para_id: ParaId, local: Arc<L>, polkado
finalized_heads
.map(|head_data| {
<Option<<L::Block as BlockT>::Header>>::decode(&mut &head_data[..])
<<L::Block as BlockT>::Header>::decode(&mut &head_data[..])
.map_err(|_| Error::InvalidHeadData)
})
.try_filter_map(|h| future::ready(Ok(h)))
.try_for_each(move |p_head| {
future::ready(local.finalize(p_head.hash()).map_err(Error::Client).map(|_| ()))
})
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment