diff hgext/largefiles/overrides.py @ 18152:4454607b5d25

largefiles: remove findoutgoing portability wrapper
author Mads Kiilerich <madski@unity3d.com>
date Thu, 13 Dec 2012 19:19:06 +0100
parents 14e31a631e41
children 51837a31b425
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py	Thu Dec 13 19:19:06 2012 +0100
+++ b/hgext/largefiles/overrides.py	Thu Dec 13 19:19:06 2012 +0100
@@ -12,7 +12,7 @@
 import copy
 
 from mercurial import hg, commands, util, cmdutil, scmutil, match as match_, \
-    node, archival, error, merge
+    node, archival, error, merge, discovery
 from mercurial.i18n import _
 from mercurial.node import hex
 from hgext import rebase
@@ -976,10 +976,10 @@
         remote = hg.peer(repo, opts, dest)
     except error.RepoError:
         return None
-    o = lfutil.findoutgoing(repo, remote, False)
-    if not o:
-        return o
-    o = repo.changelog.nodesbetween(o, revs)[0]
+    outgoing = discovery.findcommonoutgoing(repo, remote.peer(), force=False)
+    if not outgoing.missing:
+        return outgoing.missing
+    o = repo.changelog.nodesbetween(outgoing.missing, revs)[0]
     if opts.get('newest_first'):
         o.reverse()