We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 60fe70d commit b0ba8dbCopy full SHA for b0ba8db
src/parsers/message.rs
@@ -267,13 +267,11 @@ impl MessageParser {
267
let is_inline = is_inline
268
&& part_headers
269
.header_value(&HeaderName::ContentDisposition)
270
- .map_or(true, |d| {
271
- !d.as_content_type().is_some_and(|ct| ct.is_attachment())
272
- })
+ .is_none_or(|d| !d.as_content_type().is_some_and(|ct| ct.is_attachment()))
273
&& (state.parts == 1
274
|| state.mime_type != MimeType::MultipartRelated
275
&& (mime_type == MimeType::Inline
276
- || content_type.map_or(true, |c| !c.has_attribute("name"))));
+ || content_type.is_none_or(|c| !c.has_attribute("name"))));
277
278
// if message consists of single text/plain part, classify as text regardless
279
// of encoding issues: see malformed/018.eml
0 commit comments