Skip to content

Commit 087d3bc

Browse files
TPKatoJ-F-Liu
authored andcommitted
return Option via ok() instead of unwrap() for decode_text_string
1 parent dec5ec6 commit 087d3bc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/reader.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -615,7 +615,7 @@ impl Reader<'_> {
615615
match dict.get(key) {
616616
Ok(obj) => match obj {
617617
Object::String(_bytes, _) => {
618-
Some(common_data_structures::decode_text_string(obj).unwrap())
618+
common_data_structures::decode_text_string(obj).ok()
619619
}
620620
_ => None,
621621
},

0 commit comments

Comments
 (0)