| 579 | } |
| 580 | |
| 581 | bool CWallet::RemoveKey(const CKey &key) { |
| 582 | CKeyID keyId = key.GetPubKey().GetKeyId(); |
| 583 | |
| 584 | if (!IsEncrypted()) { //unencrypted or unlocked |
| 585 | CWalletDB(strWalletFile).EraseKeyStoreValue(keyId); |
| 586 | mapKeys.erase(keyId); |
| 587 | } else { |
| 588 | return ERRORMSG("wallet is being locked hence no key removal!"); |
| 589 | } |
| 590 | |
| 591 | return true; |
| 592 | } |
| 593 | |
| 594 | bool CWallet::IsReadyForColdMining(const CAccountDBCache &accountView) const { |
| 595 | CRegID regId; |
no test coverage detected