localrepo: use revsymbol in lookupbranch() too
authorMartin von Zweigbergk <martinvonz@google.com>
Wed, 04 Apr 2018 14:57:58 -0700
changeset 37352 92171562c7f3
parent 37351 fdd22bf6398f
child 37353 ac666c5c2e0c
localrepo: use revsymbol in lookupbranch() too lookupbranch() takes a string that comes from the CLI, so scmutil.revsymbol() is appropriate for looking it up. Differential Revision: https://phab.mercurial-scm.org/D3080
mercurial/localrepo.py
--- a/mercurial/localrepo.py	Wed Apr 04 14:31:09 2018 -0700
+++ b/mercurial/localrepo.py	Wed Apr 04 14:57:58 2018 -0700
@@ -1023,7 +1023,7 @@
         if key in self.branchmap():
             return key
 
-        return self[key].branch()
+        return scmutil.revsymbol(self, key).branch()
 
     def known(self, nodes):
         cl = self.changelog