kontroller sub-class
The following readme describes all the functions and their parameters exposed by the kontroller
class of the KETH SDK.
NOTE: The kontroller sub-class functions can only be used by the DAO.
execute function
Can be used to call a function on the target contract that requires DAO clearance.
Input Parameters
target: The target contract address
data: Function calldata to be passed
value: ETH value to be sent
Using execute function
await sdk.kontroller.execute(target, data, value);
Return Parameter
Transaction details if the transaction is successful.
pauseByGuardian function
This function allows the guardian to pause the target contract.
Input Parameters
target: The target contract address
Using pauseByGuardian function
await sdk.kontroller.pauseByGuardian(target);
Return Parameter
Transaction details if the transaction is successful.
updateGuardian function
This function allows the DAO to update the guardian.
Input Parameters
guardian: The new guardian address
isEnabled: Set true to enable guardian
Using updateGuardian function
await sdk.kontroller.updateGuardian(guardian, isEnabled);
Return Parameter
Transaction details if the transaction is successful.