diff hgext/patchbomb.py @ 2889:20b95aef3fe0

Move ui.sendmail to mail.connect/sendmail
author Matt Mackall <mpm@selenic.com>
date Tue, 15 Aug 2006 14:06:50 -0500
parents 58a679745b38
children 13cd2cdeff6a
line wrap: on
line diff
--- a/hgext/patchbomb.py	Tue Aug 15 11:34:08 2006 -0500
+++ b/hgext/patchbomb.py	Tue Aug 15 14:06:50 2006 -0500
@@ -241,7 +241,7 @@
     ui.write('\n')
 
     if not opts['test'] and not opts['mbox']:
-        mail = ui.sendmail()
+        mailer = mail.connect(ui)
     parent = None
 
     # Calculate UTC offset
@@ -290,7 +290,7 @@
             ui.status('Sending ', m['Subject'], ' ...\n')
             # Exim does not remove the Bcc field
             del m['Bcc']
-            mail.sendmail(sender, to + bcc + cc, m.as_string(0))
+            mailer.sendmail(sender, to + bcc + cc, m.as_string(0))
 
 cmdtable = {
     'email':