mirror of
https://github.com/XRPLF/clio.git
synced 2025-12-06 17:27:58 +00:00
@@ -17,8 +17,34 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <rpc/RPCHelpers.h>
|
||||
#include <rpc/handlers/AccountChannels.h>
|
||||
#include "rpc/handlers/AccountChannels.h"
|
||||
|
||||
#include "rpc/Errors.h"
|
||||
#include "rpc/JS.h"
|
||||
#include "rpc/RPCHelpers.h"
|
||||
#include "rpc/common/Types.h"
|
||||
|
||||
#include <boost/json/conversion.hpp>
|
||||
#include <boost/json/object.hpp>
|
||||
#include <boost/json/value.hpp>
|
||||
#include <ripple/basics/base_uint.h>
|
||||
#include <ripple/basics/strHex.h>
|
||||
#include <ripple/protocol/AccountID.h>
|
||||
#include <ripple/protocol/ErrorCodes.h>
|
||||
#include <ripple/protocol/Indexes.h>
|
||||
#include <ripple/protocol/LedgerFormats.h>
|
||||
#include <ripple/protocol/LedgerHeader.h>
|
||||
#include <ripple/protocol/PublicKey.h>
|
||||
#include <ripple/protocol/SField.h>
|
||||
#include <ripple/protocol/STLedgerEntry.h>
|
||||
#include <ripple/protocol/jss.h>
|
||||
#include <ripple/protocol/tokens.h>
|
||||
|
||||
#include <optional>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <variant>
|
||||
#include <vector>
|
||||
|
||||
namespace rpc {
|
||||
|
||||
@@ -77,7 +103,7 @@ AccountChannelsHandler::process(AccountChannelsHandler::Input input, Context con
|
||||
: std::optional<ripple::AccountID>{};
|
||||
|
||||
Output response;
|
||||
auto const addToResponse = [&](ripple::SLE&& sle) {
|
||||
auto const addToResponse = [&](ripple::SLE const sle) {
|
||||
if (sle.getType() == ripple::ltPAYCHAN && sle.getAccountID(ripple::sfAccount) == accountID &&
|
||||
(!destAccountID || *destAccountID == sle.getAccountID(ripple::sfDestination))) {
|
||||
addChannel(response.channels, sle);
|
||||
|
||||
Reference in New Issue
Block a user