mirror of
https://github.com/XRPLF/rippled.git
synced 2026-08-22 23:00:55 +00:00
feat: Hook up base_fee host function
This commit is contained in:
@@ -95,6 +95,18 @@ HostContext::getParentLedgerHash(rust::Slice<std::uint8_t> out) const noexcept
|
||||
});
|
||||
}
|
||||
|
||||
std::int32_t
|
||||
HostContext::getBaseFee(rust::Slice<std::uint8_t> out) const noexcept
|
||||
{
|
||||
return guarded(hostFunctions_.getJournal(), kHostInternal, [&] {
|
||||
auto const fee = hostFunctions_.getBaseFee();
|
||||
if (!fee)
|
||||
return hfErrorToInt(fee.error());
|
||||
|
||||
return answerScalar(out, *fee);
|
||||
});
|
||||
}
|
||||
|
||||
std::int32_t
|
||||
HostContext::getCurrentLedgerObjField(std::int32_t field, rust::Slice<std::uint8_t> out)
|
||||
const noexcept
|
||||
|
||||
Reference in New Issue
Block a user