Securing Your Withdrawal Contract
Learn More About the Withdrawal Contracts:
🛡️Withdrawal ContractsAs a pool owner, it is your responsibility to keep your Withdrawal Contract up to date, or your pool will immediately go under Recovery Mode.
Checking for Upgrades
// compare these 2 version IDs:
const lastVersion = await Portal.getWithdrawalContractVersion();
const currentVersion = await WithdrawalContract.getContractVersion();
const needs_upgrade = lastVersion != currentVersion ;
Fetching an Upgrade Proposal
Anyone can fetch an upgrade proposal and force your Staking Pool into Recovery Mode.
However, only the Controller can approve this upgrade proposal to effectively change the code:
await WithdrawalContract.fetchUpgradeProposal();
Upgrade
await WithdrawalContract.upgradeTo(newImplementation);
It is always best practice to be in touch with us, in order to be notified for potential upgrades: Join Geode's Discord
Last updated