stalwartlabs / mail-builder

E-mail builder library for Rust
https://docs.rs/mail-builder/
Apache License 2.0
54 stars 17 forks source link

fix incorrect new lines in headers #13

Open npajkovsky opened 1 year ago

npajkovsky commented 1 year ago

multiline header like Received

Received: Text("from 139-162-244-188.cprapid.com\n\tby 139-162-244-188.cprapid.com with LMTP\n\tid RQb5Ojfdd2O5LikAqCNTnA\n\t(envelope-from pajkovsky@139-162-244-188.cprapid.com)\n\tfor pajkovsky@139-162-244-188.cprapid.com; Fri, 18 Nov 2022 19:29:59 +0000")

was incorrectly rendered

Received: from 139-162-244-188.cprapid.com by 139-162-244-188.cprapid.com with LMTP id RQb5Ojfdd2O5LikAqCNTnA (envelope-from pajkovsky@139-162-244-188.cprapid.com)

    for <pajkovsky@139-162-244-188.cprapid.com>; Fri, 18 Nov 2022 19:29:59 +0000

but the output

Received: from 139-162-244-188.cprapid.com by 139-162-244-188.cprapid.com with LMTP id RQb5Ojfdd2O5LikAqCNTnA (envelope-from pajkovsky@139-162-244-188.cprapid.com) for pajkovsky@139-162-244-188.cprapid.com; Fri, 18 Nov 2022 19:29:59 +0000

The patch removes adding line folding for Text. Probably incorrect.