In case something goes wrong with contract, and it gets unable to continue working properly, the owner should be able to enable a emergency exit, which allows StakeVaults to leave without any processing inside of the contract.
StakeManager would have a new global boolean emergencyExit = false which can be set by setEmergencyExit(true) by only owner. StakeVault would have a emergencyExit() function which would read StakeManager 'emergencyExit' flag and if true, allow withdraw.
Also consider using error handling on StakeVault.emergencyExit() to allow withdraw if reading flag gives an error different than out of gas.
In case something goes wrong with contract, and it gets unable to continue working properly, the owner should be able to enable a emergency exit, which allows StakeVaults to leave without any processing inside of the contract.
StakeManager would have a new global boolean
emergencyExit = falsewhich can be set by setEmergencyExit(true) by only owner. StakeVault would have a emergencyExit() function which would read StakeManager 'emergencyExit' flag and if true, allow withdraw.Also consider using error handling on StakeVault.emergencyExit() to allow withdraw if reading flag gives an error different than out of gas.