Accessible msg error and type changes

This commit is contained in:
René Rössler
2020-10-08 11:51:04 +02:00
parent 893e4b91ba
commit 9739c0305b
5 changed files with 68 additions and 16 deletions

View File

@@ -223,7 +223,7 @@ impl MimeMessage {
if warn_empty_signature && parser.signatures.is_empty() {
for part in parser.parts.iter_mut() {
part.error = "No valid signature".to_string();
part.error = Some("No valid signature".to_string());
}
}
@@ -589,7 +589,7 @@ impl MimeMessage {
part.typ = Viewtype::Text;
part.msg_raw = Some(txt.clone());
part.msg = txt;
part.error = "Decryption failed".to_string();
part.error = Some("Decryption failed".to_string());
self.parts.push(part);
@@ -1179,7 +1179,7 @@ pub struct Part {
pub bytes: usize,
pub param: Params,
org_filename: Option<String>,
pub error: String,
pub error: Option<String>,
}
/// return mimetype and viewtype for a parsed mail