diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -1209,8 +1209,6 @@ std::string fromAccount, CReserveKey &reservekey, CConnman *connman, CValidationState &state); - void ListAccountCreditDebit(const std::string &strAccount, - std::list &entries); bool AddAccountingEntry(const CAccountingEntry &); bool AddAccountingEntry(const CAccountingEntry &, WalletBatch *batch); bool DummySignTx(CMutableTransaction &txNew, const std::set &txouts, diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -3482,12 +3482,6 @@ return true; } -void CWallet::ListAccountCreditDebit(const std::string &strAccount, - std::list &entries) { - WalletBatch batch(*database); - return batch.ListAccountCreditDebit(strAccount, entries); -} - bool CWallet::AddAccountingEntry(const CAccountingEntry &acentry) { WalletBatch batch(*database); diff --git a/src/wallet/walletdb.h b/src/wallet/walletdb.h --- a/src/wallet/walletdb.h +++ b/src/wallet/walletdb.h @@ -210,7 +210,6 @@ /// Erase destination data tuple from wallet database. bool EraseDestData(const CTxDestination &address, const std::string &key); - Amount GetAccountCreditDebit(const std::string &strAccount); void ListAccountCreditDebit(const std::string &strAccount, std::list &acentries); diff --git a/src/wallet/walletdb.cpp b/src/wallet/walletdb.cpp --- a/src/wallet/walletdb.cpp +++ b/src/wallet/walletdb.cpp @@ -190,18 +190,6 @@ acentry); } -Amount WalletBatch::GetAccountCreditDebit(const std::string &strAccount) { - std::list entries; - ListAccountCreditDebit(strAccount, entries); - - Amount nCreditDebit = Amount::zero(); - for (const CAccountingEntry &entry : entries) { - nCreditDebit += entry.nCreditDebit; - } - - return nCreditDebit; -} - void WalletBatch::ListAccountCreditDebit(const std::string &strAccount, std::list &entries) { bool fAllAccounts = (strAccount == "*");