src/topic/destination.py
changeset 1878 c44f161575ba
parent 1871 58ef5699fb35
child 1891 077c40f206d1
--- a/src/topic/destination.py	Thu Dec 31 11:23:19 2015 -0500
+++ b/src/topic/destination.py	Sat Mar 12 12:36:25 2016 +0000
@@ -4,7 +4,7 @@
 from mercurial import extensions
 from mercurial.i18n import _
 
-def _destmergebranch(orig, repo):
+def _destmergebranch(orig, repo, action='merge', sourceset=None, onheadcheck=True):
     p1 = repo['.']
     top = p1.topic()
     if top:
@@ -37,7 +37,10 @@
                               % (top, len(heads)))
         else:
             assert False # that's impossible
-    return orig(repo)
+    if orig.func_default: # version above hg-3.7
+        return orig(repo, action, sourceset, onheadcheck)
+    else:
+        return orig(repo)
 
 def setupdest():
     if util.safehasattr(destutil, '_destmergebranch'):