Skip to main content
Version: 1.15.0

Function: assertLockboxOwner()

assertLockboxOwner(operation: string, chain: EVMChain, lockbox: string, sender: string): Promise<void>

Defined in: cct/evm/lockbox/contracts.ts:313

Pre-flights sender against the lockbox's on-chain owner() for an owner-gated write, so an unauthorized caller fails as a CCTParamsInvalidError here instead of as an OnlyCallableByOwner revert after a multisig has already reviewed and signed. The lockbox-side counterpart of assertPoolOwner and assertTokenOwner.

Parameters​

ParameterTypeDescription
operationstringOperation name, for the error's operation field.
chainEVMChainChain to read the owner from.
lockboxstringLockbox being written to.
senderstringThe address the tx will be sent from; compared checksummed.

Returns​

Promise<void>

Throws​

CCTParamsInvalidError if sender is not the lockbox owner