diff --git a/src/ripple/app/hook/impl/HookAPI.cpp b/src/ripple/app/hook/impl/HookAPI.cpp index 84af7b3ca..7e735732e 100644 --- a/src/ripple/app/hook/impl/HookAPI.cpp +++ b/src/ripple/app/hook/impl/HookAPI.cpp @@ -585,6 +585,15 @@ HookAPI::ledger_last_hash() const return hookCtx.applyCtx.view().info().parentHash; } +uint64_t +HookAPI::ledger_last_time() const +{ + return hookCtx.applyCtx.view() + .info() + .parentCloseTime.time_since_epoch() + .count(); +} + Expected HookAPI::ledger_nonce() const {