mirror of
https://github.com/XRPLF/clio.git
synced 2026-06-03 00:36:44 +00:00
Fix: Duplicate messages when subscribe both accounts and proposed_accounts (#1415)
Fix #1134
This commit is contained in:
@@ -240,7 +240,11 @@ SubscriptionSource::handleMessage(std::string const& message)
|
||||
|
||||
} else {
|
||||
if (isForwarding_) {
|
||||
if (object.contains(JS(transaction))) {
|
||||
// Clio as rippled's proposed_transactions subscirber, will receive two jsons for each transaction
|
||||
// 1 - Proposed transaction
|
||||
// 2 - Validated transaction
|
||||
// Only forward proposed transaction, validated transactions are sent by Clio itself
|
||||
if (object.contains(JS(transaction)) and !object.contains(JS(meta))) {
|
||||
subscriptions_->forwardProposedTransaction(object);
|
||||
} else if (object.contains(JS(type)) && object.at(JS(type)) == JS_ValidationReceived) {
|
||||
subscriptions_->forwardValidation(object);
|
||||
|
||||
Reference in New Issue
Block a user