Serialize metadata as blob in tx RPC when binary flag is true

This commit is contained in:
CJ Cobb
2021-03-10 16:46:19 -05:00
committed by manojsdoshi
parent f0424fe7dd
commit 207e1730e9
2 changed files with 20 additions and 2 deletions

View File

@@ -236,7 +236,14 @@ doTxHelp(RPC::Context& context, TxArgs const& args)
if (ledger && meta)
{
result.meta = meta;
if (args.binary)
{
result.meta = meta->getAsObject().getSerializer().getData();
}
else
{
result.meta = meta;
}
result.validated = isValidated(
context.ledgerMaster, ledger->info().seq, ledger->info().hash);
}