templater: replace 'ctx._repo' with 'ctx.repo()'
authorMatt Harbison <matt_harbison@yahoo.com>
Thu, 12 Mar 2015 23:11:15 -0400
changeset 24337 696ab1a24ae0
parent 24336 c9f4ef967a1d
child 24338 ca1365078c86
templater: replace 'ctx._repo' with 'ctx.repo()'
mercurial/templatekw.py
mercurial/templater.py
--- a/mercurial/templatekw.py	Thu Mar 12 23:08:16 2015 -0400
+++ b/mercurial/templatekw.py	Thu Mar 12 23:11:15 2015 -0400
@@ -397,7 +397,7 @@
 def shownames(namespace, **args):
     """helper method to generate a template keyword for a namespace"""
     ctx = args['ctx']
-    repo = ctx._repo
+    repo = ctx.repo()
     ns = repo.names[namespace]
     names = ns.names(repo, ctx.node())
     return showlist(ns.templatename, names, plural=namespace, **args)
--- a/mercurial/templater.py	Thu Mar 12 23:08:16 2015 -0400
+++ b/mercurial/templater.py	Thu Mar 12 23:11:15 2015 -0400
@@ -391,7 +391,7 @@
 
     raw = args[0][1]
     ctx = mapping['ctx']
-    repo = ctx._repo
+    repo = ctx.repo()
 
     def query(expr):
         m = revsetmod.match(repo.ui, expr)