diff options
author | Teddy Wing | 2021-03-14 18:22:50 +0100 |
---|---|---|
committer | Teddy Wing | 2021-03-14 18:22:50 +0100 |
commit | 225ee75ef33986fc26271952bfd688da81435ad1 (patch) | |
tree | 966df545f4d8b920ebfae50da7f3204544148e94 | |
parent | de0bed481b794e224ec76865aff6cc9cfee02ec8 (diff) | |
download | mutt-ottolangy-225ee75ef33986fc26271952bfd688da81435ad1.tar.bz2 |
Remove TODOs and debug output from multipart and HTML work
Now that we've handled 'multipart/relative' and HTML-only
'text/plain'-less emails, we can remove these.
-rw-r--r-- | src/main.rs | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/src/main.rs b/src/main.rs index ee2899e..394053f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -115,7 +115,6 @@ fn run() -> Result<(), OttolangyError> { let lang_info = whatlang::detect(&body) .ok_or(OttolangyError::DetectLanguage)?; - println!("lang: {:?}", lang_info); let attribution_config = if lang_info.lang() == Lang::Fra { ATTRIBUTION_FR } else { @@ -135,8 +134,6 @@ fn run() -> Result<(), OttolangyError> { fn get_email_body(email: &[u8]) -> Result<String, WrapError> { let email = mailparse::parse_mail(&email)?; - println!("ctype: {:?}", email.ctype); - if email.subparts.is_empty() { let mut body = email.get_body()?; @@ -144,15 +141,9 @@ fn get_email_body(email: &[u8]) -> Result<String, WrapError> { body = unhtml(&body)?; } - println!("body: {:?}", body); - return Ok(body); } - // TODO: If no plain text part, use html one - // TODO: New predicate function for text/plain - // TODO: Maybe split into functions - extract_multipart_email_body(&email) } |