From 87661a2611c6062748a0b51df08f8e6fc1559bbd Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Tue, 27 Feb 2024 18:01:11 -0500 Subject: [PATCH] chore: support 1.65 --- src/lib.rs | 3 ++- src/mime.rs | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index ddd509f..936fe9f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -58,7 +58,8 @@ impl Clipboard { if let Ok(reply) = self.request_receiver.recv() { match reply { - Ok((data, mime)) => T::try_from((data, mime)).map_err(std::io::Error::other), + Ok((data, mime)) => T::try_from((data, mime)) + .map_err(|err| std::io::Error::new(std::io::ErrorKind::Other, err)), Err(err) => Err(err), } } else { diff --git a/src/mime.rs b/src/mime.rs index 5bda1a0..cd538dc 100644 --- a/src/mime.rs +++ b/src/mime.rs @@ -19,16 +19,16 @@ pub enum MimeType { /// text/plain;charset=utf-8 mime type. /// /// The primary mime type used by most clients - TextPlainUtf8 = 0, + TextPlainUtf8, /// UTF8_STRING mime type. /// /// Some X11 clients are using only this mime type, so we /// should have it as a fallback just in case. - Utf8String = 1, + Utf8String, /// text/plain mime type. /// /// Fallback without charset parameter. - TextPlain = 2, + TextPlain, /// Other mime type Other(Cow<'static, str>), }