From fbc2a0bc56ab75affd8dc4277ad04940ce0d21a4 Mon Sep 17 00:00:00 2001 From: MaxVerevkin Date: Wed, 5 Mar 2025 16:09:40 +0200 Subject: fix clippy::clippy::io_other_error --- src/i3bar_protocol.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/i3bar_protocol.rs b/src/i3bar_protocol.rs index 8aee9af..d0a371a 100644 --- a/src/i3bar_protocol.rs +++ b/src/i3bar_protocol.rs @@ -100,10 +100,10 @@ impl Protocol { *self = Self::JsonNotStarted { header }; self.process_new_bytes(rem) } - Ok((Some(header), _)) => Err(Error::new( - ErrorKind::Other, - format!("Protocol version {} is not supported", header.version), - )), + Ok((Some(header), _)) => Err(Error::other(format!( + "Protocol version {} is not supported", + header.version + ))), _ => { *self = Self::PlainText { pending_line: None }; self.process_new_bytes(bytes) -- cgit v1.3.1