mirror of
https://github.com/XRPLF/rippled.git
synced 2026-06-07 10:47:05 +00:00
refactor: rename info() to header() (#6138)
This change renames all the `info()` functions to `header()`, since they return `LedgerHeader` structs. It also renames the underlying variables from `info_` to `header_`.
This commit is contained in:
@@ -67,7 +67,8 @@ Env::AppBundle::AppBundle(
|
||||
app->logs().threshold(thresh);
|
||||
if (!app->setup({}))
|
||||
Throw<std::runtime_error>("Env::AppBundle: setup failed");
|
||||
timeKeeper->set(app->getLedgerMaster().getClosedLedger()->info().closeTime);
|
||||
timeKeeper->set(
|
||||
app->getLedgerMaster().getClosedLedger()->header().closeTime);
|
||||
app->start(false /*don't start timers*/);
|
||||
thread = std::thread([&]() { app->run(); });
|
||||
|
||||
@@ -107,7 +108,7 @@ Env::close(
|
||||
// Round up to next distinguishable value
|
||||
using namespace std::chrono_literals;
|
||||
bool res = true;
|
||||
closeTime += closed()->info().closeTimeResolution - 1s;
|
||||
closeTime += closed()->header().closeTimeResolution - 1s;
|
||||
timeKeeper().set(closeTime);
|
||||
// Go through the rpc interface unless we need to simulate
|
||||
// a specific consensus delay.
|
||||
@@ -130,7 +131,7 @@ Env::close(
|
||||
res = false;
|
||||
}
|
||||
}
|
||||
timeKeeper().set(closed()->info().closeTime);
|
||||
timeKeeper().set(closed()->header().closeTime);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user