hgext/inhibit.py
changeset 1583 aaa65373a31b
parent 1582 aa42a6ad9c5c
child 1588 983f2e4dbe5d
--- a/hgext/inhibit.py	Sun Jan 10 10:52:24 2016 -0800
+++ b/hgext/inhibit.py	Thu Jan 14 12:02:38 2016 -0800
@@ -190,11 +190,11 @@
     finally:
         lockmod.release(tr, lock)
 
-def _computeobsoletenotrebasedwrap(orig, repo, rebasesetrevs, dest):
+def _filterobsoleterevswrap(orig, repo, rebasesetrevs, *args, **kwargs):
     repo._notinhibited = rebasesetrevs
     try:
         repo.invalidatevolatilesets()
-        r = orig(repo, rebasesetrevs, dest)
+        r = orig(repo, rebasesetrevs, *args, **kwargs)
     finally:
         del repo._notinhibited
         repo.invalidatevolatilesets()
@@ -258,9 +258,10 @@
     try:
         rebase = extensions.find('rebase')
         if rebase:
-            extensions.wrapfunction(rebase,
-                                    '_computeobsoletenotrebased',
-                                    _computeobsoletenotrebasedwrap)
+            if util.safehasattr(rebase, '_filterobsoleterevs'):
+                extensions.wrapfunction(rebase,
+                                        '_filterobsoleterevs',
+                                        _filterobsoleterevswrap)
     except KeyError:
         pass
     # There are two ways to save bookmark changes during a transation, we