Skip to content

Commit 25a6557

Browse files
committed
walletdb: move IsWalletLoaded to walletdb.cpp
1 parent f6fc5f3 commit 25a6557

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

src/wallet/db.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,6 @@ bool IsBDBWalletLoaded(const fs::path& wallet_path)
7979
return database && database->IsDatabaseLoaded(database_filename);
8080
}
8181

82-
bool IsWalletLoaded(const fs::path& wallet_path)
83-
{
84-
return IsBDBWalletLoaded(wallet_path);
85-
}
86-
8782
fs::path WalletDataFilePath(const fs::path& wallet_path)
8883
{
8984
fs::path env_directory;

src/wallet/db.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@ class BerkeleyEnvironment
8888

8989
/** Return whether a wallet database is currently loaded. */
9090
bool IsBDBWalletLoaded(const fs::path& wallet_path);
91-
bool IsWalletLoaded(const fs::path& wallet_path);
9291

9392
/** Given a wallet directory path or legacy file path, return path to main data file in the wallet database. */
9493
fs::path WalletDataFilePath(const fs::path& wallet_path);

src/wallet/walletdb.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1018,3 +1018,8 @@ bool WalletBatch::TxnAbort()
10181018
{
10191019
return m_batch.TxnAbort();
10201020
}
1021+
1022+
bool IsWalletLoaded(const fs::path& wallet_path)
1023+
{
1024+
return IsBDBWalletLoaded(wallet_path);
1025+
}

src/wallet/walletdb.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,4 +289,7 @@ void MaybeCompactWalletDB();
289289
//! Unserialize a given Key-Value pair and load it into the wallet
290290
bool ReadKeyValue(CWallet* pwallet, CDataStream& ssKey, CDataStream& ssValue, std::string& strType, std::string& strErr);
291291

292+
/** Return whether a wallet database is currently loaded. */
293+
bool IsWalletLoaded(const fs::path& wallet_path);
294+
292295
#endif // BITCOIN_WALLET_WALLETDB_H

0 commit comments

Comments
 (0)