Skip to main content
Version: v2.x

Minimal Anti Collusion Infrastructure (MACI) / contractExists

Function: contractExists()

contractExists(provider, address): Promise<boolean>

Defined in: packages/sdk/ts/utils/contracts.ts:9

Small utility function to check whether a contract exists at a given address

Parameters

provider

Provider

the provider to use to interact with the chain

address

string

the address of the contract to check

Returns

Promise<boolean>

a boolean indicating whether the contract exists