def METHOD_NAME(self, recipient):
    yesterday = datetime.date.today() - datetime.timedelta(days=1)
    yesterday_string = yesterday.strftime("%d %b %Y")
    table = self._generate_report_table()
    file_to_attach = io.BytesIO()
    export_from_tables(
        [[yesterday_string, table]],
        file_to_attach,
        Format.XLS_2007
    )
    email_context = {
        'date_of_report': yesterday_string,
    }
    email_content = render_to_string(
        'accounting/email/credits_on_hq.html', email_context)
    email_content_plaintext = render_to_string(
        'accounting/email/credits_on_hq.txt', email_context)
    format_dict = Format.FORMAT_DICT[Format.XLS_2007]
    file_attachment = {
        'title': 'Credits_on_hq_{}_{}'.format(
            yesterday.isoformat(),
            settings.SERVER_ENVIRONMENT,
        ),
        'mimetype': format_dict['mimetype'],
        'file_obj': file_to_attach,
    }
    from_email = "Dimagi Finance <{}>".format(settings.DEFAULT_FROM_EMAIL)
    send_HTML_email(
        "{} Credits on HQ {}".format(
            yesterday_string,
            settings.SERVER_ENVIRONMENT,
        ),
        recipient,
        email_content,
        email_from=from_email,
        text_content=email_content_plaintext,
        file_attachments=[file_attachment],
    )