1
Fork 0
mirror of https://github.com/Steffo99/patched-porobot.git synced 2024-12-22 17:44:22 +00:00

Use Result::is_ok() instead of pattern matching in Deck::read_f1_extra

This commit is contained in:
Steffo 2022-08-22 18:18:05 +02:00
parent d869d6d943
commit 139de76961
Signed by: steffo
GPG key ID: 6965406171929D01

View file

@ -227,7 +227,7 @@ impl Deck {
fn read_f1_extra<R: Read>(reader: &mut R, contents: &mut HashMap<CardCode, u32>) -> 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(())
}