stablerange: stop using '.index' in 'rangelength'
authorPierre-Yves David <pierre-yves.david@ens-lyon.org>
Wed, 22 Mar 2017 17:52:53 +0100
changeset 2159 9b052257c743
parent 2158 efcfc99e82a4
child 2160 66b774ed1335
stablerange: stop using '.index' in 'rangelength' We now access '[1]' as we'll do with the future tuple.
hgext3rd/evolve/stablerange.py
--- a/hgext3rd/evolve/stablerange.py	Wed Mar 22 17:52:29 2017 +0100
+++ b/hgext3rd/evolve/stablerange.py	Wed Mar 22 17:52:53 2017 +0100
@@ -239,7 +239,7 @@
         return revdepth
 
     def rangelength(self, repo, rangeid):
-        headrev, index = rangeid[0], rangeid.index
+        headrev, index = rangeid[0], rangeid[1]
         return self.depthrev(repo, headrev) - index
 
     def subranges(self, repo, rangeid):