Update to the latest substrate

This commit is contained in:
Luke Parker 2022-11-11 03:49:02 -05:00
parent 0fb9d4397f
commit 2411660bd8
No known key found for this signature in database
GPG key ID: F9F1386DB1E119B6
2 changed files with 3 additions and 3 deletions
substrate/tendermint/client/src

View file

@ -102,7 +102,7 @@ impl<T: TendermintValidator> TendermintAuthority<T> {
&mut self
.import
.client
.justifications(&BlockId::Hash(info.finalized_hash))
.justifications(info.finalized_hash)
.unwrap()
.map(|justifications| justifications.get(CONSENSUS_ID).cloned().unwrap())
.unwrap_or_default()
@ -350,7 +350,7 @@ impl<T: TendermintValidator> Network for TendermintAuthority<T> {
self
.import
.client
.finalize_block(BlockId::Hash(hash), Some(justification), true)
.finalize_block(hash, Some(justification), true)
.map_err(|_| Error::InvalidJustification)
.unwrap();

View file

@ -22,7 +22,7 @@ impl<T: TendermintValidator> TendermintImport<T> {
// This can be triggered if the validators add a block, without justifications, yet the p2p
// process then broadcasts it with its justifications
if (self.client.status(id).unwrap() == BlockStatus::InChain) &&
self.client.justifications(&id).unwrap().is_some()
self.client.justifications(hash).unwrap().is_some()
{
return true;
}