Skip to content

Commit 72751ba

Browse files
committed
reenable the response processing of the connector
1 parent 11b99a8 commit 72751ba

File tree

1 file changed

+6
-4
lines changed
  • crates/interledger-settlement-engines/src/engines/ethereum_ledger

1 file changed

+6
-4
lines changed

crates/interledger-settlement-engines/src/engines/ethereum_ledger/eth_engine.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -504,6 +504,7 @@ where
504504
debug!("Making POST to {:?} {:?} about {:?}", url, amount, tx_hash);
505505

506506
// settle for amount + leftovers
507+
let self_clone = self.clone();
507508
self.store
508509
.pop_leftovers(account_id.clone())
509510
.and_then(move |leftovers| {
@@ -523,6 +524,8 @@ where
523524
let url = url.clone();
524525
let account_id_clone = account_id.clone();
525526
let full_amount_clone = full_amount.clone();
527+
let account_id_clone2 = account_id.clone();
528+
let full_amount_clone2 = full_amount.clone();
526529

527530
let action = move || {
528531
let account_id = account_id.clone();
@@ -539,18 +542,17 @@ where
539542
);
540543
})
541544
};
542-
543545
Retry::spawn(
544546
ExponentialBackoff::from_millis(10).take(MAX_RETRIES),
545547
action,
546548
)
547549
.map_err(move |_| {
548-
error!("Exceeded max retries when notifying connector about account {:?} for amount {:?} and transaction hash {:?}. Please check your API.", account_id_clone, full_amount_clone, tx_hash)
550+
error!("Exceeded max retries when notifying connector about account {:?} for amount {:?} and transaction hash {:?}. Please check your API.", account_id_clone2, full_amount_clone2, tx_hash)
549551
})
550552
.and_then(move |response| {
551553
trace!("Accounting system responded with {:?}", response);
552-
Ok(()) // This call causes the type_length_error
553-
// self_clone.process_connector_response(account_id_clone2, response, full_amount.clone())
554+
// Ok(()) // This call causes the type_length_error
555+
self_clone.process_connector_response(account_id_clone, response, full_amount_clone)
554556
})
555557
})
556558
})

0 commit comments

Comments
 (0)