Skip to content

Commit

Permalink
Avoid exception
Browse files Browse the repository at this point in the history
  • Loading branch information
yagopv committed Sep 25, 2024
1 parent 401bc29 commit 855907c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions packages/protocol-kit/src/contracts/BaseContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,10 @@ class BaseContract<ContractAbiType extends Abi> {
) {
const deployment = getContractDeployment(safeVersion, chainId, contractName)

if (!deployment) {
throw new Error(`Deployment details not found for ${contractName} on chain ID ${chainId}`)
}

const resolvedAddress =
customContractAddress ??
this.#resolveAddress(
deployment.networkAddresses[chainId.toString()],
deployment?.networkAddresses[chainId.toString()],
deployment,
deploymentType
)
Expand Down

0 comments on commit 855907c

Please sign in to comment.