diff hgext/bugzilla.py @ 37087:f0b6fbea00cf

stringutil: bulk-replace call sites to point to new module This might conflict with other patches floating around, sorry.
author Yuya Nishihara <yuya@tcha.org>
date Thu, 22 Mar 2018 21:56:20 +0900
parents 386c1e45e671
children a8a902d7176e
line wrap: on
line diff
--- a/hgext/bugzilla.py	Thu Mar 22 21:19:31 2018 +0900
+++ b/hgext/bugzilla.py	Thu Mar 22 21:56:20 2018 +0900
@@ -307,6 +307,9 @@
     url,
     util,
 )
+from mercurial.utils import (
+    stringutil,
+)
 
 xmlrpclib = util.xmlrpclib
 
@@ -1099,7 +1102,8 @@
                root=self.repo.root,
                webroot=webroot(self.repo.root))
         data = self.ui.popbuffer()
-        self.bzdriver.updatebug(bugid, newstate, data, util.email(ctx.user()))
+        self.bzdriver.updatebug(bugid, newstate, data,
+                                stringutil.email(ctx.user()))
 
     def notify(self, bugs, committer):
         '''ensure Bugzilla users are notified of bug change.'''
@@ -1119,6 +1123,6 @@
         if bugs:
             for bug in bugs:
                 bz.update(bug, bugs[bug], ctx)
-            bz.notify(bugs, util.email(ctx.user()))
+            bz.notify(bugs, stringutil.email(ctx.user()))
     except Exception as e:
         raise error.Abort(_('Bugzilla error: %s') % e)