Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Fix inconsistent head_data #18

Merged
merged 2 commits into from
Oct 21, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions consensus/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,10 @@ 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)))
.and_then(|h| future::ready(Ok(h)))
gui1117 marked this conversation as resolved.
Show resolved Hide resolved
.try_for_each(move |p_head| {
future::ready(local.finalize(p_head.hash()).map_err(Error::Client).map(|_| ()))
})
Expand Down