diff mercurial/bundlerepo.py @ 30474:43924f3a55fa

bundlerepo: use supportedincomingversions instead of allsupportedversions Since bundlerepo is really a pull-like operation, this is the correct method to use here.
author Augie Fackler <augie@google.com>
date Thu, 04 Aug 2016 14:13:35 -0400 (2016-08-04)
parents 9e88077f972c
children 55d341877316
line wrap: on
line diff
--- a/mercurial/bundlerepo.py
+++ b/mercurial/bundlerepo.py
@@ -290,7 +290,8 @@
                                                   "multiple changegroups")
                     cgstream = part
                     version = part.params.get('version', '01')
-                    if version not in changegroup.allsupportedversions(ui):
+                    legalcgvers = changegroup.supportedincomingversions(self)
+                    if version not in legalcgvers:
                         msg = _('Unsupported changegroup version: %s')
                         raise error.Abort(msg % version)
                     if self.bundle.compressed():