Include amendments in validations subscription

This commit is contained in:
wilsonianb
2016-03-25 16:18:55 -07:00
committed by Nik Bougalis
parent 3a45ef0e65
commit fa02409c92
2 changed files with 8 additions and 1 deletions

View File

@@ -1630,6 +1630,13 @@ void NetworkOPsImp::pubValidation (STValidation::ref val)
if (seq != 0)
jvObj [jss::ledger_index] = to_string (seq);
if (val->isFieldPresent (sfAmendments))
{
jvObj[jss::amendments] = Json::Value (Json::arrayValue);
for (auto const& amendment : val->getFieldV256(sfAmendments))
jvObj [jss::amendments].append (to_string (amendment));
}
for (auto i = mSubValidations.begin (); i != mSubValidations.end (); )
{
if (auto p = i->second.lock())

View File

@@ -78,7 +78,7 @@ JSS ( affected ); // out: AcceptedLedgerTx
JSS ( age ); // out: NetworkOPs, Peers
JSS ( alternatives ); // out: PathRequest, RipplePathFind
JSS ( amendment_blocked ); // out: NetworkOPs
JSS ( amendments ); // in: AccountObjects
JSS ( amendments ); // in: AccountObjects, out: NetworkOPs
JSS ( asks ); // out: Subscribe
JSS ( assets ); // out: GatewayBalances
JSS ( authorized ); // out: AccountLines