mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2026-03-06 16:07:22 +01:00
Fixed UP032 (f-string): Use f-string instead of format call
This commit is contained in:
committed by
Joshua Tauberer
parent
b7f70b17ac
commit
2b426851f9
@@ -30,15 +30,11 @@ print("IMAP login is OK.")
|
||||
# Attempt to send a mail to ourself.
|
||||
mailsubject = "Mail-in-a-Box Automated Test Message " + uuid.uuid4().hex
|
||||
emailto = emailaddress
|
||||
msg = """From: {emailaddress}
|
||||
msg = f"""From: {emailaddress}
|
||||
To: {emailto}
|
||||
Subject: {subject}
|
||||
Subject: {mailsubject}
|
||||
|
||||
This is a test message. It should be automatically deleted by the test script.""".format(
|
||||
emailaddress=emailaddress,
|
||||
emailto=emailto,
|
||||
subject=mailsubject,
|
||||
)
|
||||
This is a test message. It should be automatically deleted by the test script."""
|
||||
|
||||
# Connect to the server on the SMTP submission TLS port.
|
||||
server = smtplib.SMTP_SSL(host)
|
||||
|
||||
Reference in New Issue
Block a user