From RjS: Don't send mail if we don't have any recipients...

- Legacy-Id: 2223
This commit is contained in:
Henrik Levkowetz 2010-04-16 11:16:20 +00:00
parent 9e6b6e63f9
commit f416f13dc4

View file

@ -52,7 +52,8 @@ for draft in matches:
continue
"""
send_mail_subj(None, to_addrs, None, 'notify_expirations/subject.txt', 'notify_expirations/body.txt',
if to_addrs or cc_addrs:
send_mail_subj(None, to_addrs, None, 'notify_expirations/subject.txt', 'notify_expirations/body.txt',
{
'draft':draft,
'expiration':expiration,