mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
ForkCondition: some small refactors (#10712)
This commit is contained in:
@ -68,7 +68,7 @@ impl ChainHardforks {
|
||||
/// Retrieves [`ForkCondition`] from `fork`. If `fork` is not present, returns
|
||||
/// [`ForkCondition::Never`].
|
||||
pub fn fork<H: Hardfork>(&self, fork: H) -> ForkCondition {
|
||||
self.get(fork).unwrap_or(ForkCondition::Never)
|
||||
self.get(fork).unwrap_or_default()
|
||||
}
|
||||
|
||||
/// Retrieves [`ForkCondition`] from `fork` if it exists, otherwise `None`.
|
||||
|
||||
Reference in New Issue
Block a user