compat: drop compatibility layer for 'tryimportone'
Return is now homogeneous for all the version we support.
--- a/hgext3rd/evolve/__init__.py Tue Feb 28 14:25:35 2017 +0100
+++ b/hgext3rd/evolve/__init__.py Tue Feb 28 14:27:08 2017 +0100
@@ -1030,11 +1030,7 @@
@eh.wrapfunction(mercurial.cmdutil, 'tryimportone')
def tryimportone(orig, ui, repo, hunk, parents, opts, *args, **kwargs):
extracted = patch.extract(ui, hunk)
- if util.safehasattr(extracted, 'get'):
- # mercurial 3.6 return a dictionary there
- expected = extracted.get('nodeid')
- else:
- expected = extracted[5]
+ expected = extracted.get('nodeid')
if expected is not None:
expected = node.bin(expected)
oldextract = patch.extract