# HG changeset patch # User Michael Tharp # Date 1289837321 18000 # Node ID 988ad510ef9751bab5ae09da7f8e266ca9f77b7c # Parent 90f5bf44cf599edc180ad1c59c9a01b0fec302c6 Fix HTTP 'forests' command on hg >= 1.7 (#1) diff -r 90f5bf44cf59 -r 988ad510ef97 forest.py --- a/forest.py Mon Oct 11 12:58:05 2010 -0400 +++ b/forest.py Mon Nov 15 11:08:41 2010 -0500 @@ -274,7 +274,13 @@ raise util.Abort(_("Remote forests cannot be cloned because the " "other repository doesn't support the forest " "extension.")) - data = self.do_read("forests", walkhg=("", "True")[walkhg]) + if hasattr(self, 'do_read'): + # < 1.7 + func = self.do_read + else: + # >= 1.7 + func = self._call + data = func("forests", walkhg=("", "True")[walkhg]) return data.splitlines() httprepo.httprepository.forests = _httprepo_forests