diff roundup/anypy/email_.py @ 5494:b7fa56ced601

use gpg module instead of pyme module for PGP encryption
author Christof Meerwald <cmeerw@cmeerw.org>
date Sun, 12 Aug 2018 16:17:14 +0100
parents 45bfb4bf59c2
children 29346d92d80c
line wrap: on
line diff
--- a/roundup/anypy/email_.py	Sun Aug 12 16:15:10 2018 +0100
+++ b/roundup/anypy/email_.py	Sun Aug 12 16:17:14 2018 +0100
@@ -3,6 +3,11 @@
 import email
 from email import quoprimime, base64mime
 
+if str == bytes:
+    message_from_bytes = email.message_from_string
+else:
+    message_from_bytes = email.message_from_bytes
+
 ## please import this file if you are using the email module
 
 # Match encoded-word strings in the form =?charset?q?Hello_World?=

Roundup Issue Tracker: http://roundup-tracker.org/