From cee86072181aed942e025703fc7e98157b67602d Mon Sep 17 00:00:00 2001 From: ThomasV Date: Thu, 13 Feb 2020 11:49:05 +0100 Subject: [PATCH] save_backup: use db.dump() to clone the db --- electrum/wallet.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/electrum/wallet.py b/electrum/wallet.py index c6ccaae55..9e22e6ab0 100644 --- a/electrum/wallet.py +++ b/electrum/wallet.py @@ -264,10 +264,9 @@ class Abstract_Wallet(AddressSynchronizer, ABC): self.db.write(self.storage) def save_backup(self, path, *, old_password=None, new_password=None): - new_db = WalletDB(self.storage.read(), manual_upgrades=False) + new_db = WalletDB(self.db.dump(), manual_upgrades=False) new_db.put('is_backup', True) new_storage = WalletStorage(path) - #new_storage._encryption_version = self.storage.get_encryption_version() new_storage._encryption_version = StorageEncryptionVersion.PLAINTEXT w2 = Wallet(new_db, new_storage, config=self.config) if new_password: