Some simple Option / Result / iterator pattern simplifications (#3205)
This commit is contained in:
committed by
GitHub
parent
616dad43fd
commit
dcdbdd4bcc
@@ -463,10 +463,7 @@ impl KernelHandler {
|
||||
height,
|
||||
mmr_index,
|
||||
});
|
||||
match kernel {
|
||||
Some(kernel) => Ok(kernel),
|
||||
None => Err(ErrorKind::NotFound.into()),
|
||||
}
|
||||
kernel.ok_or_else(|| ErrorKind::NotFound.into())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user