Mercurial > evolve
changeset 417:a1fb18ad29a1 stable
evolve: avoid duplication in graft wrapper
author | Patrick Mezard <patrick@mezard.eu> |
---|---|
date | Sat, 04 Aug 2012 12:48:20 +0200 |
parents | 22f348c25d25 |
children | 18a0d96ed559 |
files | hgext/evolve.py |
diffstat | 1 files changed, 1 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/evolve.py Sat Aug 04 12:28:21 2012 +0200 +++ b/hgext/evolve.py Sat Aug 04 12:48:20 2012 +0200 @@ -634,16 +634,15 @@ lock.release() def graftwrapper(orig, ui, repo, *revs, **kwargs): + obsoleted = kwargs.setdefault('obsolete', []) lock = repo.lock() try: if kwargs.get('old_obsolete'): - obsoleted = kwargs.setdefault('obsolete', []) if kwargs['continue']: obsoleted.extend(repo.opener.read('graftstate').splitlines()) else: obsoleted.extend(revs) # convert obsolete target into revs to avoid alias joke - obsoleted = kwargs.setdefault('obsolete', []) obsoleted[:] = [str(i) for i in repo.revs('%lr', obsoleted)] if obsoleted and len(revs) > 1: