mirror of
https://github.com/mimblewimble/grin.git
synced 2025-01-20 19:11:08 +03:00
fix v2 conversion to ensure we provide blocks in correct format (#3465)
This commit is contained in:
parent
cf2a65242d
commit
145c2874f5
1 changed files with 2 additions and 2 deletions
|
@ -372,8 +372,8 @@ where
|
||||||
self.chain()
|
self.chain()
|
||||||
.get_block(&h)
|
.get_block(&h)
|
||||||
.map(|b| match peer_info.version.value() {
|
.map(|b| match peer_info.version.value() {
|
||||||
0..=2 => Some(b),
|
0..=2 => self.chain().convert_block_v2(b).ok(),
|
||||||
3..=ProtocolVersion::MAX => self.chain().convert_block_v2(b).ok(),
|
3..=ProtocolVersion::MAX => Some(b),
|
||||||
})
|
})
|
||||||
.unwrap_or(None)
|
.unwrap_or(None)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue