Sfoglia il codice sorgente

Authentication is only applied when both the username and password have values. (#2937)

tags/0.6.0-preview-workflow.1
Leo Q 1 anno fa
parent
commit
cc754122fc
Nessun account collegato all'indirizzo email del committer
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1
    1
      api/libs/smtp.py

+ 1
- 1
api/libs/smtp.py Vedi File

@@ -16,7 +16,7 @@ class SMTPClient:
smtp = smtplib.SMTP(self.server, self.port)
if self._use_tls:
smtp.starttls()
if (self.username):
if self.username and self.password:
smtp.login(self.username, self.password)
msg = MIMEMultipart()
msg['Subject'] = mail['subject']

Loading…
Annulla
Salva