Skip to content

Commit 15e599a

Browse files
committed
Fix a clippy suggestion
1 parent 8a4bae6 commit 15e599a

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

imap-proto/src/parser/tests.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -488,9 +488,8 @@ fn test_imap_body_structure() {
488488

489489
let parser = BodyStructParser::new(bodystructure);
490490

491-
let element = parser.search(|b: &BodyStructure| match *b {
492-
BodyStructure::Basic { ref common, .. } if common.ty.ty == "APPLICATION" => true,
493-
_ => false,
491+
let element = parser.search(|b: &BodyStructure| {
492+
matches!(b, BodyStructure::Basic { ref common, .. } if common.ty.ty == "APPLICATION")
494493
});
495494

496495
assert_eq!(element, Some(vec![2]));

0 commit comments

Comments
 (0)