mercurial/hgweb/hgwebdir_mod.py
branchstable
changeset 25426 5f3666da6910
parent 25396 78e8890cfb4b
child 25427 d0c7ffc4c8bc
equal deleted inserted replaced
25425:9263f86b9681 25426:5f3666da6910
   290                         discarded = '/'.join(nameparts[1:])
   290                         discarded = '/'.join(nameparts[1:])
   291 
   291 
   292                         # remove name parts plus accompanying slash
   292                         # remove name parts plus accompanying slash
   293                         path = path[:-len(discarded) - 1]
   293                         path = path[:-len(discarded) - 1]
   294 
   294 
       
   295                         try:
       
   296                             r = hg.repository(self.ui, path)
       
   297                             directory = False
       
   298                         except (IOError, error.RepoError):
       
   299                             pass
       
   300 
   295                 parts = [name]
   301                 parts = [name]
   296                 if 'PATH_INFO' in req.env:
   302                 if 'PATH_INFO' in req.env:
   297                     parts.insert(0, req.env['PATH_INFO'].rstrip('/'))
   303                     parts.insert(0, req.env['PATH_INFO'].rstrip('/'))
   298                 if req.env['SCRIPT_NAME']:
   304                 if req.env['SCRIPT_NAME']:
   299                     parts.insert(0, req.env['SCRIPT_NAME'])
   305                     parts.insert(0, req.env['SCRIPT_NAME'])