mirror of
https://github.com/serai-dex/serai.git
synced 2025-03-12 09:26:51 +00:00
cargo fmt
This commit is contained in:
parent
05b1fc5f05
commit
aa0ec4ac41
1 changed files with 7 additions and 1 deletions
|
@ -144,7 +144,13 @@ impl<D: Db, T: Transaction, P: P2p> Tributary<D, T, P> {
|
|||
self.network.blockchain.read().unwrap().block(hash)
|
||||
}
|
||||
pub fn time_of_block(&self, hash: &[u8; 32]) -> Option<u64> {
|
||||
self.network.blockchain.read().unwrap().commit(hash).map(|commit| Commit::<Validators>::decode(&mut commit.as_ref()).unwrap().end_time)
|
||||
self
|
||||
.network
|
||||
.blockchain
|
||||
.read()
|
||||
.unwrap()
|
||||
.commit(hash)
|
||||
.map(|commit| Commit::<Validators>::decode(&mut commit.as_ref()).unwrap().end_time)
|
||||
}
|
||||
pub fn commit(&self, hash: &[u8; 32]) -> Option<Vec<u8>> {
|
||||
self.network.blockchain.read().unwrap().commit(hash)
|
||||
|
|
Loading…
Reference in a new issue