remote-bzr: add support for older versions
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Felipe Contreras committed
Apr 9, 2014 at 13:50 UTC
5ff569908dd6e174c2d81df8e25ecc8af34fc5a8
1 file changed
+2
-2
contrib/remote-helpers/git-remote-bzr
+2
-2
@@ -759,7 +759,7 @@ def clone(path, remote_branch):
759
def get_remote_branch(name):
760
remote_branch = bzrlib.branch.Branch.open(branches[name],
761
possible_transports=transports)
762
- if isinstance(remote_branch.user_transport, bzrlib.transport.local.LocalTransport):
762
+ if isinstance(remote_branch.bzrdir.root_transport, bzrlib.transport.local.LocalTransport):
763
return remote_branch
764
765
branch_path = os.path.join(dirname, 'clone', name)
@@ -842,7 +842,7 @@ def get_repo(url, alias):
842
if not wanted:
843
try:
844
repo = origin.open_repository()
845
- if not repo.user_transport.listable():
845
+ if not repo.bzrdir.root_transport.listable():
846
# this repository is not usable for us
847
raise bzrlib.errors.NoRepositoryPresent(repo.bzrdir)
848
except bzrlib.errors.NoRepositoryPresent: