I'm afraid much of this conditional block is handled by `email.message.Message.get_payload` if you pass it the proper arguments -- http://docs.python.org/2/library/email.message.html#email.message.Message.get_payload -- good catch, though; I should definitely be decoding the payload components.