Commit 1f1d4a50 authored by Barry Warsaw's avatar Barry Warsaw

Use absolute import paths for intrapackage imports.

as_string(): Use Generator.flatten() for better performance.
parent 8e178fc7
...@@ -10,9 +10,9 @@ from cStringIO import StringIO ...@@ -10,9 +10,9 @@ from cStringIO import StringIO
from types import ListType, StringType from types import ListType, StringType
# Intrapackage imports # Intrapackage imports
import Errors from email import Errors
import Utils from email import Utils
import Charset from email import Charset
SEMISPACE = '; ' SEMISPACE = '; '
...@@ -78,10 +78,10 @@ class Message: ...@@ -78,10 +78,10 @@ class Message:
Optional `unixfrom' when true, means include the Unix From_ envelope Optional `unixfrom' when true, means include the Unix From_ envelope
header. header.
""" """
from Generator import Generator from email.Generator import Generator
fp = StringIO() fp = StringIO()
g = Generator(fp) g = Generator(fp)
g(self, unixfrom=unixfrom) g.flatten(self, unixfrom=unixfrom)
return fp.getvalue() return fp.getvalue()
def is_multipart(self): def is_multipart(self):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment