X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Frouting%2Frouter.rs;fp=lightning%2Fsrc%2Frouting%2Frouter.rs;h=a8da26c23a630959190439f179cf1e00eb9a652c;hb=0f2c4c0d7008b2af3165859b1c6dec8d16a672c4;hp=7342e813a9ed906d4f6a45412203106a7445c59e;hpb=d327c231cf7f998a8f588898841a385ac5cee58e;p=rust-lightning diff --git a/lightning/src/routing/router.rs b/lightning/src/routing/router.rs index 7342e813..a8da26c2 100644 --- a/lightning/src/routing/router.rs +++ b/lightning/src/routing/router.rs @@ -417,7 +417,7 @@ impl Readable for Route { let blinded_tails = blinded_tails.unwrap_or(Vec::new()); if blinded_tails.len() != 0 { if blinded_tails.len() != paths.len() { return Err(DecodeError::InvalidValue) } - for (mut path, blinded_tail_opt) in paths.iter_mut().zip(blinded_tails.into_iter()) { + for (path, blinded_tail_opt) in paths.iter_mut().zip(blinded_tails.into_iter()) { path.blinded_tail = blinded_tail_opt; } } @@ -1221,7 +1221,7 @@ impl<'a> PaymentPath<'a> { cur_hop_fees_msat = self.hops.get(i + 1).unwrap().0.hop_use_fee_msat; } - let mut cur_hop = &mut self.hops.get_mut(i).unwrap().0; + let cur_hop = &mut self.hops.get_mut(i).unwrap().0; cur_hop.next_hops_fee_msat = total_fee_paid_msat; // Overpay in fees if we can't save these funds due to htlc_minimum_msat. // We try to account for htlc_minimum_msat in scoring (add_entry!), so that nodes don't