diff options
| author | Edward Barnard | 2017-06-07 13:02:19 +0100 |
|---|---|---|
| committer | Edward Barnard | 2017-06-07 13:02:19 +0100 |
| commit | b0d6118889409aa6fb13a7855d5ede17c3d11cc1 (patch) | |
| tree | 0ea95cbbc0db52c98549642b3da1a9f82895ec69 /src/xml | |
| parent | 1bbe75304c630ce585fa2da3dfdff2482c21c78f (diff) | |
| download | rust-plist-b0d6118889409aa6fb13a7855d5ede17c3d11cc1.tar.bz2 | |
Address some clippy warnings.
Diffstat (limited to 'src/xml')
| -rw-r--r-- | src/xml/reader.rs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/xml/reader.rs b/src/xml/reader.rs index e536033..465d264 100644 --- a/src/xml/reader.rs +++ b/src/xml/reader.rs @@ -109,9 +109,10 @@ impl<R: Read> EventReader<R> { } } Ok(XmlEvent::EndDocument) => { - match self.element_stack.is_empty() { - true => return None, - false => return Some(Err(Error::UnexpectedEof)), + if self.element_stack.is_empty() { + return None; + } else { + return Some(Err(Error::UnexpectedEof)); } } Err(_) => return Some(Err(Error::InvalidData)), |
