mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-07 00:42:42 +00:00
Remove expect
This commit is contained in:
@@ -60,6 +60,7 @@ pub enum Error {
|
|||||||
BrokenBlock {
|
BrokenBlock {
|
||||||
block_root: Hash256,
|
block_root: Hash256,
|
||||||
},
|
},
|
||||||
|
NoViableChildren,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<ArithError> for Error {
|
impl From<ArithError> for Error {
|
||||||
|
|||||||
@@ -1338,7 +1338,7 @@ impl ProtoArray {
|
|||||||
(*weight, child.root, *payload_status_tiebreaker)
|
(*weight, child.root, *payload_status_tiebreaker)
|
||||||
})
|
})
|
||||||
.map(|(child, _, _)| child)
|
.map(|(child, _, _)| child)
|
||||||
.expect("children is non-empty");
|
.ok_or(Error::NoViableChildren)?;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user