use routing::network_graph::NodeId;
use routing::router::RouteHop;
-use prelude::*;
use core::cell::{RefCell, RefMut};
use core::ops::DerefMut;
use sync::{Mutex, MutexGuard};
fn channel_penalty_msat(&self, short_channel_id: u64, source: &NodeId, target: &NodeId) -> u64;
/// Handles updating channel penalties after failing to route through a channel.
- fn payment_path_failed(&mut self, path: &Vec<RouteHop>, short_channel_id: u64);
+ fn payment_path_failed(&mut self, path: &[&RouteHop], short_channel_id: u64);
}
/// A scorer that is accessed under a lock.
self.deref().channel_penalty_msat(short_channel_id, source, target)
}
- fn payment_path_failed(&mut self, path: &Vec<RouteHop>, short_channel_id: u64) {
+ fn payment_path_failed(&mut self, path: &[&RouteHop], short_channel_id: u64) {
self.deref_mut().payment_path_failed(path, short_channel_id)
}
}