BlockId removal: refactor: Backend::justifications (#6229)

* BlockId removal: refactor: Backend::justifications

It changes the arguments of `Backend::justifications` method from: `BlockId<Block>` to: `&Block::Hash`

This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)

* formatting

* update lockfile for {"substrate"}

Co-authored-by: parity-processbot <>
This commit is contained in:
Michal Kucharczykandparity-processbot authored and GitHub committed 2022-11-02 22:59:27 +00:00
1 parent 6d83525b50
commit a4a5fa8523
2 files changed
+185 -182

No files matched your search

+180 -180
View File
File diff suppressed because it is too large. Load diff
+5 -2
View File
@@ -358,12 +358,15 @@ impl sc_client_api::BlockBackend<Block> for Client {
}
}
fn justifications(&self, id: &BlockId<Block>) -> sp_blockchain::Result<Option<Justifications>> {
fn justifications(
&self,
hash: &<Block as BlockT>::Hash,
) -> sp_blockchain::Result<Option<Justifications>> {
with_client! {
self,
client,
{
client.justifications(id)
client.justifications(hash)
}
}
}