X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Futil%2Ferrors.rs;h=17e55a9799bb503c987782a2937c52a00634abdf;hb=0fa67fb96c19290039eb424d40a05de92b7a3e02;hp=f00d2ab2d0e741a3b833b56b90ec8edae7fbce93;hpb=31042ab7d524d75a1e9eb34080c1bdc666c9101e;p=rust-lightning diff --git a/lightning/src/util/errors.rs b/lightning/src/util/errors.rs index f00d2ab2..17e55a97 100644 --- a/lightning/src/util/errors.rs +++ b/lightning/src/util/errors.rs @@ -9,7 +9,7 @@ //! Error types live here. -use ln::script::ShutdownScript; +use crate::ln::script::ShutdownScript; use alloc::string::String; use core::fmt; @@ -35,7 +35,7 @@ pub enum APIError { }, /// A malformed Route was provided (eg overflowed value, node id mismatch, overly-looped route, /// too-many-hops, etc). - RouteError { + InvalidRoute { /// A human-readable error message err: &'static str }, @@ -74,7 +74,7 @@ impl fmt::Debug for APIError { match *self { APIError::APIMisuseError {ref err} => write!(f, "Misuse error: {}", err), APIError::FeeRateTooHigh {ref err, ref feerate} => write!(f, "{} feerate: {}", err, feerate), - APIError::RouteError {ref err} => write!(f, "Route error: {}", err), + APIError::InvalidRoute {ref err} => write!(f, "Invalid route provided: {}", err), APIError::ChannelUnavailable {ref err} => write!(f, "Channel unavailable: {}", err), APIError::MonitorUpdateInProgress => f.write_str("Client indicated a channel monitor update is in progress but not yet complete"), APIError::IncompatibleShutdownScript { ref script } => {