compat: drop compatibility dance around configoverride
authorPierre-Yves David <pierre-yves.david@octobus.net>
Wed, 25 Oct 2017 07:32:06 +0200
changeset 3150 95c77ef938ef
parent 3149 79a926b557f1
child 3151 41c72b6e8568
compat: drop compatibility dance around configoverride This was introduced in hg-4.1 and we do no longer support lower versions.
hgext3rd/topic/__init__.py
--- a/hgext3rd/topic/__init__.py	Wed Oct 25 04:45:31 2017 +0200
+++ b/hgext3rd/topic/__init__.py	Wed Oct 25 07:32:06 2017 +0200
@@ -769,11 +769,8 @@
 
         # phase handling
         commitphase = c.phase()
-        if util.safehasattr(repo.ui, 'configoverride'):
-            overrides = {('phases', 'new-commit'): commitphase}
-            with repo.ui.configoverride(overrides, 'changetopic'):
-                newnode = repo.commitctx(mc)
-        else: # do not attempt to preserver phase (hg <= 4.0)
+        overrides = {('phases', 'new-commit'): commitphase}
+        with repo.ui.configoverride(overrides, 'changetopic'):
             newnode = repo.commitctx(mc)
 
         successors[c.node()] = (newnode,)