mq: avoid using revlog.nodemap unnecessarily
authorMatt Mackall <mpm@selenic.com>
Tue, 11 Jan 2011 17:06:07 -0600
changeset 13256 996b95985c2f
parent 13255 2696730ca233
child 13257 d1245ce817a8
mq: avoid using revlog.nodemap unnecessarily
hgext/mq.py
--- a/hgext/mq.py	Tue Jan 11 17:01:14 2011 -0600
+++ b/hgext/mq.py	Tue Jan 11 17:06:07 2011 -0600
@@ -2942,7 +2942,7 @@
 
             mqtags = [(patch.node, patch.name) for patch in q.applied]
 
-            if mqtags[-1][0] not in self.changelog.nodemap:
+            if mqtags[-1][0] not in self:
                 self.ui.warn(_('mq status file refers to unknown node %s\n')
                              % short(mqtags[-1][0]))
                 return result
@@ -2967,7 +2967,7 @@
 
             cl = self.changelog
             qbasenode = q.applied[0].node
-            if qbasenode not in cl.nodemap:
+            if qbasenode not in self:
                 self.ui.warn(_('mq status file refers to unknown node %s\n')
                              % short(qbasenode))
                 return super(mqrepo, self)._branchtags(partial, lrev)