From: W. Trevor King Date: Sat, 11 May 2013 10:52:12 +0000 (-0400) Subject: email: Pass 'config' and 'section' through from send() to *_send() X-Git-Tag: v3.4~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=a33bd8e1832b7ccb735bd79badd78525cb490687;p=rss2email.git email: Pass 'config' and 'section' through from send() to *_send() Otherwise only the default configuration will be used, which is almost certainly not what the user wants. Signed-off-by: W. Trevor King --- diff --git a/rss2email/email.py b/rss2email/email.py index bf5ecab..1b26a18 100644 --- a/rss2email/email.py +++ b/rss2email/email.py @@ -334,8 +334,12 @@ def sendmail_send(sender, recipient, message, config=None, section='DEFAULT'): def send(sender, recipient, message, config=None, section='DEFAULT'): protocol = config.get(section, 'email-protocol') if protocol == 'smtp': - smtp_send(sender, recipient, message) + smtp_send( + sender=sender, recipient=recipient, message=message, + config=config, section=section) elif protocol == 'imap': - imap_send(message) + imap_send(message=message, config=config, section=section) else: - sendmail_send(sender, recipient, message) + sendmail_send( + sender=sender, recipient=recipient, message=message, + config=config, section=section)