def getbodytext(self, decode = 1): if not decode: return self.bodyencoded if type(self.body) == type(''): return self.body