mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
feat: Support unnamed OP chains (#8488)
This commit is contained in:
@ -20,8 +20,9 @@ impl NetworkStackId {
|
||||
/// ENR fork ID kv-pair key, for an Optimism CL node.
|
||||
pub const OPSTACK: &'static [u8] = b"opstack";
|
||||
|
||||
#[allow(clippy::missing_const_for_fn)]
|
||||
/// Returns the [`NetworkStackId`] that matches the given [`ChainSpec`].
|
||||
pub const fn id(chain: &ChainSpec) -> Option<&'static [u8]> {
|
||||
pub fn id(chain: &ChainSpec) -> Option<&'static [u8]> {
|
||||
if chain.is_optimism() {
|
||||
return Some(Self::OPEL)
|
||||
} else if chain.is_eth() {
|
||||
|
||||
Reference in New Issue
Block a user