directaccess: register config item if possible
Mercurial 4.4 warns about unregistered config.
--- a/hgext3rd/evolve/hack/directaccess.py Thu Oct 19 14:46:06 2017 +0200
+++ b/hgext3rd/evolve/hack/directaccess.py Thu Oct 19 18:17:47 2017 +0200
@@ -24,6 +24,14 @@
from mercurial import cmdutil
command = cmdutil.command(cmdtable)
+if util.safehasattr(registrar, 'configitem'):
+ configtable = {}
+ configitem = registrar.configitem(configtable)
+
+ configitem('directaccess', 'loadsafter',
+ default=[],
+ )
+
# By default, all the commands have directaccess with warnings
# List of commands that have no directaccess and directaccess with no warning
directaccesslevel = [