summaryrefslogtreecommitdiffstats
path: root/ipc
diff options
context:
space:
mode:
Diffstat (limited to 'ipc')
-rw-r--r--ipc/src/assuan/mod.rs15
1 files changed, 3 insertions, 12 deletions
diff --git a/ipc/src/assuan/mod.rs b/ipc/src/assuan/mod.rs
index 0e503308..a3276210 100644
--- a/ipc/src/assuan/mod.rs
+++ b/ipc/src/assuan/mod.rs
@@ -416,26 +416,17 @@ impl Response {
/// Returns true if this message indicates success.
pub fn is_ok(&self) -> bool {
- match self {
- Response::Ok { .. } => true,
- _ => false,
- }
+ matches!(self, Response::Ok { .. } )
}
/// Returns true if this message indicates an error.
pub fn is_err(&self) -> bool {
- match self {
- Response::Error { .. } => true,
- _ => false,
- }
+ matches!(self, Response::Error { .. })
}
/// Returns true if this message is an inquiry.
pub fn is_inquire(&self) -> bool {
- match self {
- Response::Inquire { .. } => true,
- _ => false,
- }
+ matches!(self, Response::Inquire { .. })
}
/// Returns true if this response concludes the server's response.