Bind to s instead of e

This error variant contains a string not an error type, bind to local
variable `s` instead of `e` to make this explicit.
This commit is contained in:
Tobin C. Harding 2022-05-25 12:33:56 +10:00
parent 5c6d369289
commit 01f481bf5c
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ impl fmt::Display for Error {
"invalid checksum: expected {}, actual {}", e.to_hex(), a.to_hex()),
Error::NonMinimalVarInt => write!(f, "non-minimal varint"),
Error::UnknownNetworkMagic(ref m) => write!(f, "unknown network magic: {}", m),
Error::ParseFailed(ref e) => write!(f, "parse failed: {}", e),
Error::ParseFailed(ref s) => write!(f, "parse failed: {}", s),
Error::UnsupportedSegwitFlag(ref swflag) => write!(f,
"unsupported segwit version: {}", swflag),
}