evolve: drop 4.5 compat for scmutil.resolvehexnodeidprefix()
authorAnton Shestakov <av6@dwimlabs.net>
Sat, 07 Mar 2020 22:38:14 +0700
changeset 5187 4230f046ddb9
parent 5186 4bac3454beef
child 5188 43feb2380c05
evolve: drop 4.5 compat for scmutil.resolvehexnodeidprefix()
hgext3rd/evolve/evolvecmd.py
--- a/hgext3rd/evolve/evolvecmd.py	Sat Mar 07 02:26:49 2020 +0700
+++ b/hgext3rd/evolve/evolvecmd.py	Sat Mar 07 22:38:14 2020 +0700
@@ -990,10 +990,7 @@
     sha1s = re.findall(sha1re, commitmsg)
     unfi = repo.unfiltered()
     for sha1 in sha1s:
-        if util.safehasattr(scmutil, 'resolvehexnodeidprefix'): # > hg-4.6
-            fullnode = scmutil.resolvehexnodeidprefix(unfi, sha1)
-        else:
-            fullnode = unfi.changelog.index.partialmatch(sha1)
+        fullnode = scmutil.resolvehexnodeidprefix(unfi, sha1)
         if fullnode is None:
             continue
         ctx = unfi[fullnode]