diff hgsubversion/__init__.py @ 1247:3a4d74823187

pull: wrap exchange.pull if localrepository.pull isn't available Mercurial rev 73b5b8312ce6 removed localrepository.pull. We don't do it the other way round (wrap pull if exchange.pull is available) because that's been available with a different signature since Mercurial 3.0.
author Siddharth Agarwal <sid0@fb.com>
date Mon, 13 Oct 2014 23:56:13 -0700
parents 2179747e7fea
children c1756971f882
line wrap: on
line diff
--- a/hgsubversion/__init__.py
+++ b/hgsubversion/__init__.py
@@ -146,6 +146,9 @@ def extsetup(ui):
     if not hgutil.safehasattr(localrepo.localrepository, 'push'):
         # Mercurial >= 3.2
         extensions.wrapfunction(exchange, 'push', wrappers.exchangepush)
+    if not hgutil.safehasattr(localrepo.localrepository, 'pull'):
+        # Mercurial >= 3.2
+        extensions.wrapfunction(exchange, 'pull', wrappers.exchangepull)
 
     helpdir = os.path.join(os.path.dirname(__file__), 'help')