Mercurial > hg
changeset 22820:103dcfbb385f
rebase: use `last` instead of direct indexing
This makes it compatible with all smartset classes.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Tue, 07 Oct 2014 00:16:59 -0700 |
parents | 602aa2b98628 |
children | 5d4c17d11d7e |
files | hgext/rebase.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/rebase.py Tue Oct 07 00:14:53 2014 -0700 +++ b/hgext/rebase.py Tue Oct 07 00:16:59 2014 -0700 @@ -596,7 +596,7 @@ rebased = [r for r in state if state[r] > nullmerge] candidates = repo.revs('max(%ld and (::%d))', rebased, rev) if candidates: - return state[candidates[0]] + return state[candidates.first()] else: return None