#NEWLINE# def send_mail( subject , text , from_email , rec_list , html = None ) : #NEWLINE# #INDENT# '\n        Shortcut for sending email.\n        ' #NEWLINE# msg = EmailMultiAlternatives ( subject , text , from_email , rec_list ) #NEWLINE# if html : #NEWLINE# #INDENT# msg . attach_alternative ( html , 'text/html' ) #NEWLINE# #UNINDENT# msg . send ( fail_silently = True )