summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBarry Warsaw <barry@python.org>2002-06-02 19:05:51 (GMT)
committerBarry Warsaw <barry@python.org>2002-06-02 19:05:51 (GMT)
commit8ba76e8929058634ee55bea8781e32715b0ce5c2 (patch)
tree0308ef99f8ebe274e1f4dffdc9d57db66b8bc596
parent524af6f382d1d287763018abc7c6415bb3dad9b5 (diff)
downloadcpython-8ba76e8929058634ee55bea8781e32715b0ce5c2.zip
cpython-8ba76e8929058634ee55bea8781e32715b0ce5c2.tar.gz
cpython-8ba76e8929058634ee55bea8781e32715b0ce5c2.tar.bz2
Use absolute import paths for intrapackage imports.
as_string(): Use Generator.flatten() for better performance.
-rw-r--r--Lib/email/Message.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/email/Message.py b/Lib/email/Message.py
index 84a4e16..491c259 100644
--- a/Lib/email/Message.py
+++ b/Lib/email/Message.py
@@ -10,9 +10,9 @@ from cStringIO import StringIO
from types import ListType, StringType
# Intrapackage imports
-import Errors
-import Utils
-import Charset
+from email import Errors
+from email import Utils
+from email import Charset
SEMISPACE = '; '
@@ -78,10 +78,10 @@ class Message:
Optional `unixfrom' when true, means include the Unix From_ envelope
header.
"""
- from Generator import Generator
+ from email.Generator import Generator
fp = StringIO()
g = Generator(fp)
- g(self, unixfrom=unixfrom)
+ g.flatten(self, unixfrom=unixfrom)
return fp.getvalue()
def is_multipart(self):