configitems: register the 'notify.diffstat' config
authorBoris Feld <boris.feld@octobus.net>
Fri, 30 Jun 2017 03:43:19 +0200
changeset 33739 b30da11d9233
parent 33738 2069a8c336b9
child 33740 a853325102a0
configitems: register the 'notify.diffstat' config
hgext/notify.py
--- a/hgext/notify.py	Fri Jun 30 03:43:18 2017 +0200
+++ b/hgext/notify.py	Fri Jun 30 03:43:19 2017 +0200
@@ -161,6 +161,9 @@
 configitem('notify', 'config',
     default=None,
 )
+configitem('notify', 'diffstat',
+    default=True,
+)
 
 # template for single changeset can include email headers.
 single_template = '''
@@ -368,7 +371,7 @@
                             opts=patch.diffallopts(self.ui))
         difflines = ''.join(chunks).splitlines()
 
-        if self.ui.configbool('notify', 'diffstat', True):
+        if self.ui.configbool('notify', 'diffstat'):
             s = patch.diffstat(difflines)
             # s may be nil, don't include the header if it is
             if s: