diff --git a/imap-codec/src/response.rs b/imap-codec/src/response.rs index a05ab85f..f15efcf2 100644 --- a/imap-codec/src/response.rs +++ b/imap-codec/src/response.rs @@ -101,14 +101,11 @@ pub(crate) fn resp_text(input: &[u8]) -> IMAPResult<&[u8], (Option, Text)> #[cfg(feature = "quirk_missing_text")] alt(( preceded(sp, text), - value( - { - log::warn!("Rectified missing `text` to \"...\""); + map(peek(crlf), |_| { + log::warn!("Rectified missing `text` to \"...\""); - Text::unvalidated("...") - }, - peek(crlf), - ), + Text::unvalidated("...") + }), )), ))(input) } else {