mercurial/hg.py
changeset 50574 c04abc7340f1
parent 50413 3a2df812e1c7
child 50575 029fe2f012c8
equal deleted inserted replaced
50573:9a322ccd2fdc 50574:c04abc7340f1
   315     If repo is not a shared repository, returns None.
   315     If repo is not a shared repository, returns None.
   316     """
   316     """
   317     if repo.sharedpath == repo.path:
   317     if repo.sharedpath == repo.path:
   318         return None
   318         return None
   319 
   319 
   320     if util.safehasattr(repo, b'srcrepo') and repo.srcrepo:
   320     if util.safehasattr(repo, 'srcrepo') and repo.srcrepo:
   321         return repo.srcrepo
   321         return repo.srcrepo
   322 
   322 
   323     # the sharedpath always ends in the .hg; we want the path to the repo
   323     # the sharedpath always ends in the .hg; we want the path to the repo
   324     source = repo.vfs.split(repo.sharedpath)[0]
   324     source = repo.vfs.split(repo.sharedpath)[0]
   325     srcurl, branches = urlutil.parseurl(source)
   325     srcurl, branches = urlutil.parseurl(source)