diff options
author | Thomas Bruederli <bruederli@kolabsys.com> | 2015-03-11 10:36:32 -0400 |
---|---|---|
committer | Thomas Bruederli <bruederli@kolabsys.com> | 2015-03-11 10:36:32 -0400 |
commit | e0e64a93a67d03bef200a10417d4334198247aa4 (patch) | |
tree | 83e6c46046570e4ab1bdd56f9dfb47717cf92cff | |
parent | e731c861ebcb52ef33296b53f2a72099a4ae5161 (diff) | |
download | pykolab-e0e64a93a67d03bef200a10417d4334198247aa4.tar.gz |
The email.MIMEText class will take care of line wrapping; no need to do it twice
-rw-r--r-- | pykolab/utils.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/pykolab/utils.py b/pykolab/utils.py index f91ed8d..a9537dd 100644 --- a/pykolab/utils.py +++ b/pykolab/utils.py @@ -303,11 +303,7 @@ def multiline_message(message): return "\n%s\n" % ("\n".join(lines)) def stripped_message(message): - lines = [] - for line in message.strip().split("\n"): - lines.append(multiline_message(line).strip()) - - return "\n%s\n" % ("\n".join(lines)) + return "\n" + message.strip() + "\n" def str2unicode(s, encoding='utf-8'): if isinstance(s, unicode): |