Skip to content

Commit

Permalink
chore: add is granite active at timestamp (#10908)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse authored Sep 14, 2024
1 parent 646b72f commit 1c20e0e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/ethereum-forks/src/hardforks/optimism.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ pub trait OptimismHardforks: EthereumHardforks {
fn is_fjord_active_at_timestamp(&self, timestamp: u64) -> bool {
self.fork(OptimismHardfork::Ecotone).active_at_timestamp(timestamp)
}

/// Returns `true` if [`Granite`](OptimismHardfork::Granite) is active at given block timestamp.
fn is_granite_active_at_timestamp(&self, timestamp: u64) -> bool {
self.fork(OptimismHardfork::Granite).active_at_timestamp(timestamp)
}
}

impl OptimismHardforks for ChainHardforks {}

0 comments on commit 1c20e0e

Please sign in to comment.