diff options
-rw-r--r-- | Lib/email/_compat21.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/email/_compat21.py b/Lib/email/_compat21.py index 0e0b3d0..1e1f666 100644 --- a/Lib/email/_compat21.py +++ b/Lib/email/_compat21.py @@ -63,7 +63,7 @@ def typed_subpart_iterator(msg, maintype='text', subtype=None): """ parts = [] for subpart in msg.walk(): - if subpart.get_main_type('text') == maintype: - if subtype is None or subpart.get_subtype('plain') == subtype: + if subpart.get_content_maintype() == maintype: + if subtype is None or subpart.get_content_subtype() == subtype: parts.append(subpart) return parts |