Skip to content

Commit

Permalink
Base support (#83)
Browse files Browse the repository at this point in the history
Add base chain id support.
  • Loading branch information
m-lord-renkse authored Nov 5, 2024
1 parent 16445ef commit 840ba9d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/domain/eth/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ pub enum ChainId {
Mainnet = 1,
Goerli = 5,
Gnosis = 100,
Base = 8453,
ArbitrumOne = 42161,
}

Expand All @@ -22,6 +23,7 @@ impl ChainId {
1 => Ok(Self::Mainnet),
5 => Ok(Self::Goerli),
100 => Ok(Self::Gnosis),
8453 => Ok(Self::Base),
42161 => Ok(Self::ArbitrumOne),
_ => Err(UnsupportedChain),
}
Expand All @@ -33,6 +35,7 @@ impl ChainId {
ChainId::Mainnet => "1",
ChainId::Goerli => "5",
ChainId::Gnosis => "100",
ChainId::Base => "8453",
ChainId::ArbitrumOne => "42161",
}
}
Expand Down

0 comments on commit 840ba9d

Please sign in to comment.