From 301cf6318cfa3880f99eb9ec14afaf3ec8ae80c8 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Fri, 26 Mar 2021 21:58:01 -0400 Subject: [PATCH] wip --- lightning/src/routing/router.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lightning/src/routing/router.rs b/lightning/src/routing/router.rs index 2ae3218e1..b5eec1c51 100644 --- a/lightning/src/routing/router.rs +++ b/lightning/src/routing/router.rs @@ -674,7 +674,7 @@ pub fn get_route(our_node_id: &PublicKey, network: &NetworkGraph, paye // the fees included in $incl_fee_next_hops_htlc_minimum_msat, but also // can't use something that may decrease on future hops. let old_cost = cmp::max(old_entry.total_fee_msat, old_entry.path_htlc_minimum_msat); - let new_cost = cmp::max(total_fee_msat, $incl_fee_next_hops_htlc_minimum_msat); + let new_cost = cmp::max(total_fee_msat, path_htlc_minimum_msat); if new_cost < old_cost { targets.push(new_graph_node); @@ -691,7 +691,7 @@ pub fn get_route(our_node_id: &PublicKey, network: &NetworkGraph, paye }; old_entry.channel_fees = $directional_info.fees; old_entry.htlc_minimum_msat = $directional_info.htlc_minimum_msat; - old_entry.path_htlc_minimum_msat = $incl_fee_next_hops_htlc_minimum_msat; + old_entry.path_htlc_minimum_msat = path_htlc_minimum_msat; } } } -- 2.39.5