configitems: register the 'web.maxshortchanges' config
authorBoris Feld <boris.feld@octobus.net>
Wed, 11 Oct 2017 03:39:21 +0200
changeset 34588 0d9928a67254
parent 34587 b50c036494dc
child 34589 883d06211973
configitems: register the 'web.maxshortchanges' config
mercurial/configitems.py
mercurial/hgweb/hgweb_mod.py
--- a/mercurial/configitems.py	Wed Oct 11 03:36:44 2017 +0200
+++ b/mercurial/configitems.py	Wed Oct 11 03:39:21 2017 +0200
@@ -730,6 +730,9 @@
 coreconfigitem('web', 'ipv6',
     default=False,
 )
+coreconfigitem('web', 'maxshortchanges',
+    default=60,
+)
 coreconfigitem('web', 'motd',
     default='',
 )
--- a/mercurial/hgweb/hgweb_mod.py	Wed Oct 11 03:36:44 2017 +0200
+++ b/mercurial/hgweb/hgweb_mod.py	Wed Oct 11 03:39:21 2017 +0200
@@ -112,7 +112,7 @@
 
         self.maxchanges = self.configint('web', 'maxchanges', 10)
         self.stripecount = self.configint('web', 'stripes')
-        self.maxshortchanges = self.configint('web', 'maxshortchanges', 60)
+        self.maxshortchanges = self.configint('web', 'maxshortchanges')
         self.maxfiles = self.configint('web', 'maxfiles', 10)
         self.allowpull = self.configbool('web', 'allowpull', True)