changeset 22416:810d37485e85

histedit: check mutability of contexts correctly The right way to check if a context is mutable is to call .mutable(), not to compare .phase() with public.
author Augie Fackler <raf@durin42.com>
date Tue, 19 Aug 2014 14:33:01 -0400
parents 65ec6c5c0fb3
children ca854cd4a26a
files hgext/histedit.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/histedit.py	Thu Sep 11 10:14:34 2014 -0400
+++ b/hgext/histedit.py	Tue Aug 19 14:33:01 2014 -0400
@@ -751,7 +751,7 @@
         if repo.revs('(%ld) and merge()', ctxs):
             raise util.Abort(_('cannot edit history that contains merges'))
         root = ctxs[0] # list is already sorted by repo.set
-        if not root.phase():
+        if not root.mutable():
             raise util.Abort(_('cannot edit immutable changeset: %s') % root)
     return [c.node() for c in ctxs]