Skip to content

Commit 54be49d

Browse files
committed
Address PR comments.
Signed-off-by: JCW <a1q123456@users.noreply.github.com>
1 parent 6587547 commit 54be49d

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

src/xrpld/app/rdb/backend/SQLiteDatabase.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22

33
#include <xrpl/rdb/RelationalDatabase.h>
44

5+
#include <map>
56
#include <memory>
7+
#include <optional>
8+
#include <variant>
9+
#include <vector>
610

711
namespace xrpl {
812

@@ -378,7 +382,7 @@ class SQLiteDatabase final : public RelationalDatabase
378382
SQLiteDatabase&
379383
operator=(SQLiteDatabase const&) = delete;
380384
SQLiteDatabase&
381-
operator=(SQLiteDatabase&& rhs) = delete;
385+
operator=(SQLiteDatabase&&) = delete;
382386

383387
/**
384388
* @brief ledgerDbHasSpace Checks if the ledger database has available
@@ -400,7 +404,7 @@ class SQLiteDatabase final : public RelationalDatabase
400404

401405
private:
402406
ServiceRegistry& registry_;
403-
bool const useTxTables_;
407+
bool useTxTables_;
404408
beast::Journal j_;
405409
std::unique_ptr<DatabaseCon> ledgerDb_, txdb_;
406410

src/xrpld/app/rdb/backend/detail/SQLiteDatabase.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -500,12 +500,10 @@ SQLiteDatabase::getTransaction(
500500
}
501501

502502
SQLiteDatabase::SQLiteDatabase(SQLiteDatabase&& rhs) noexcept
503-
: registry_(rhs.registry_)
504-
, useTxTables_(rhs.useTxTables_)
505-
, j_(rhs.j_)
506-
, ledgerDb_(std::move(rhs.ledgerDb_))
507-
, txdb_(std::move(rhs.txdb_))
503+
: registry_(rhs.registry_), useTxTables_(rhs.useTxTables_), j_(rhs.j_)
508504
{
505+
std::exchange(ledgerDb_, std::move(rhs.ledgerDb_));
506+
std::exchange(txdb_, std::move(rhs.txdb_));
509507
}
510508

511509
bool

0 commit comments

Comments
 (0)