From 139de76961bf1029ad4a3bf045901e685a716132 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Mon, 22 Aug 2022 18:18:05 +0200 Subject: [PATCH] Use `Result::is_ok()` instead of pattern matching in `Deck::read_f1_extra` --- src/data/deckcode/deck.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/deckcode/deck.rs b/src/data/deckcode/deck.rs index 7139643..914e587 100644 --- a/src/data/deckcode/deck.rs +++ b/src/data/deckcode/deck.rs @@ -227,7 +227,7 @@ impl Deck { fn read_f1_extra(reader: &mut R, contents: &mut HashMap) -> DeckDecodingResult<()> { // While the cursor has still some bytes left... - while let Ok(_) = Self::read_f1_extra_card(reader, contents) {} + while Self::read_f1_extra_card(reader, contents).is_ok() {} Ok(()) }