Function: assertAdvancedPoolHooksOwner()
assertAdvancedPoolHooksOwner(
operation:string,chain:EVMChain,advancedPoolHooks:string,sender:string):Promise<void>
Defined in: cct/evm/advanced-pool-hooks/contracts.ts:196
Pre-flights a known sender against the AdvancedPoolHooks owner, so an unauthorized caller fails
here instead of as an OnlyCallableByOwner revert after a multisig has signed.
Parameters
| Parameter | Type | Description |
|---|---|---|
operation | string | Operation name for error context. |
chain | EVMChain | Chain hosting the hooks contract. |
advancedPoolHooks | string | Hooks contract to read. |
sender | string | Proposed transaction sender. |
Returns
Promise<void>
Remarks
The hooks are a separately owned Ownable2Step contract, not part of the pool: the
deployer becomes their owner, and binding them to a pool transfers nothing. A pool owner who did
not deploy the hooks cannot write through them, so checking the pool owner instead would pass
a sender the hooks then revert.
Throws
CCTParamsInvalidError if sender is not the current hooks owner.