From b164c44549e6a129fca8369ebfae49630f881ecf Mon Sep 17 00:00:00 2001 From: ianb Date: Sun, 3 Jul 2005 18:13:49 +0000 Subject: Another bug fix from the refactoring --- paste/urlparser.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'paste') diff --git a/paste/urlparser.py b/paste/urlparser.py index 2fd52c1..5e2d3a3 100644 --- a/paste/urlparser.py +++ b/paste/urlparser.py @@ -142,17 +142,16 @@ class URLParser(object): environ['SCRIPT_NAME'] = orig_script_name return not_found_hook(environ, start_response) if filename is None: + name, rest_of_path = wsgilib.path_info_split(environ['PATH_INFO']) if not name: - desc = 'one of %s' % ', '.join( + name = 'one of %s' % ', '.join( self.option(environ, 'index_names') or ['(no index_names defined)']) - else: - desc = name return self.not_found( environ, start_response, 'Tried to load %s from directory %s' - % (desc, self.directory)) + % (name, self.directory)) else: environ['wsgi.errors'].write( 'Found resource %s, but could not construct application\n' -- cgit v1.2.1