diff --git a/src/mailer.py b/src/mailer.py index 9a311fd..e2fe2b1 100644 --- a/src/mailer.py +++ b/src/mailer.py @@ -57,12 +57,12 @@ def sendMail(msg_body :str): with open(filename, "rb") as attachment: part = MIMEBase("application", "octet-stream") part.set_payload(attachment.read()) - encoders.encode_base64(part) - part.add_header( - "Content-Disposition", - f"attachment; filename= {filename}", - ) - message.attach(part) + encoders.encode_base64(part) + part.add_header( + "Content-Disposition", + f"attachment; filename= {filename}", + ) + message.attach(part) text = message.as_string() context = ssl.create_default_context() try: