MCPcopy Create free account
hub / github.com/PageLeay/celestial-runtime / getDeployedCode

Method getDeployedCode

lib.esm/contract/contract.js:668–676  ·  view source on GitHub ↗

* Return the deployed bytecode or null if no bytecode is found.

()

Source from the content-addressed store, hash-verified

666 * Return the deployed bytecode or null if no bytecode is found.
667 */
668 async getDeployedCode() {
669 const provider = getProvider(this.runner);
670 assert(provider, "runner does not support .provider", "UNSUPPORTED_OPERATION", { operation: "getDeployedCode" });
671 const code = await provider.getCode(await this.getAddress());
672 if (code === "0x") {
673 return null;
674 }
675 return code;
676 }
677 /**
678 * Resolve to this Contract once the bytecode has been deployed, or
679 * resolve immediately if already deployed.

Callers 2

waitForDeploymentMethod · 0.95
checkCodeMethod · 0.95

Calls 4

getAddressMethod · 0.95
assertFunction · 0.90
getProviderFunction · 0.70
getCodeMethod · 0.65

Tested by

no test coverage detected