From patchwork Fri Jan 2 23:42:05 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [4, of, 4] namespaces: remove templatename method on the namespaces object From: Sean Farley X-Patchwork-Id: 7306 Message-Id: To: mercurial-devel@selenic.com Date: Fri, 02 Jan 2015 15:42:05 -0800 # HG changeset patch # User Sean Farley # Date 1419201247 28800 # Sun Dec 21 14:34:07 2014 -0800 # Node ID d74b01f30e1010f49a7d047a6913b662e217dbc0 # Parent be5de72834c153d850c1e9c33aeb3cc26db5f088 namespaces: remove templatename method on the namespaces object Now that there is an object for each individual namespace, we use the templatename property on that object instead of the method on the collection of namespaces. diff --git a/mercurial/namespaces.py b/mercurial/namespaces.py --- a/mercurial/namespaces.py +++ b/mercurial/namespaces.py @@ -83,14 +83,10 @@ class namespaces(object): maxrev = max(cl.rev(node) for node in n) return cl.node(maxrev) return n[0] raise KeyError(_('no such name: %s') % name) - def templatename(self, namespace): - """method that returns the template name of a namespace""" - return self._names[namespace].templatename - class namespace(object): """provides an interface to a namespace Namespaces are basically generic many-to-many mapping between some (namespaced) names and nodes. The goal here is to control the pollution of