topic: handle merge.update function signature change
authorAugie Fackler <raf@durin42.com>
Thu, 31 Dec 2015 11:23:19 -0500
changeset 1877 69077c65919d
parent 1876 594ca2f3d1de
child 1878 c44f161575ba
topic: handle merge.update function signature change I think this is backwards compatible with how it used to be called, but I didn't worry about it too much either.
src/topic/__init__.py
--- a/src/topic/__init__.py	Fri Dec 11 13:12:23 2015 -0500
+++ b/src/topic/__init__.py	Thu Dec 31 11:23:19 2015 -0500
@@ -198,12 +198,11 @@
                           "\nHG: topic '%s'\nHG: branch" % t)
     return ret
 
-def mergeupdatewrap(orig, repo, node, branchmerge, force, partial,
-                    ancestor=None, mergeancestor=False, labels=None):
+def mergeupdatewrap(orig, repo, node, branchmerge, force, *args, **kwargs):
+    partial = bool(len(args)) or 'matcher' in kwargs
     wlock = repo.wlock()
     try:
-        ret = orig(repo, node, branchmerge, force, partial, ancestor=ancestor,
-                   mergeancestor=mergeancestor, labels=labels)
+        ret = orig(repo, node, branchmerge, force, *args, **kwargs)
         if not partial and not branchmerge:
             ot = repo.currenttopic
             t = ''