(self)
return Message(**message)
Prepare email message for Gmail

        :return: Gmail Email message
Prepare email message for Gmail
Prepare email message for Gmail
def _prepare_email_message(self):
        """Prepare email message for Gmail

        :return: Gmail Email message
        """
        message = {
            'subject': self.subject,
            'text': self.body,
            'sender': self.source,
            'to': self.destination,
            'cc': self.cc,
            'bcc': self.bcc,
        }

        if self.attachment:
            message.update({'attachments': list(self.attachment)})

        if self.html_message:
            message.update({'html': self.html_message})

        return Message(**message)
def _prepare_email_message ( self ) : message = { 'subject' : self . subject , 'text' : self . body , 'sender' : self . source , 'to' : self . destination , 'cc' : self . cc , 'bcc' : self . bcc , } if self . attachment : message . update ( { 'attachments' : list ( self . attachment ) } ) if self . html_message : message . update ( { 'html' : self . html_message } ) return Message ( * * message )