From 1cd5984995fefa64bdb7bdd47e6e09e8d424f6d2 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 22 Jun 2009 02:30:13 +0000 Subject: - The values of ``subpath``, ``traversed``, and ``virtual_root_path`` attached to the request object are always now tuples instead of lists (performance). --- repoze/bfg/wsgi.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'repoze/bfg/wsgi.py') diff --git a/repoze/bfg/wsgi.py b/repoze/bfg/wsgi.py index 3991d3344..545b3e93c 100644 --- a/repoze/bfg/wsgi.py +++ b/repoze/bfg/wsgi.py @@ -71,11 +71,11 @@ def wsgiapp2(wrapped): """ def decorator(context, request): traversed = request.traversed - vroot_path = request.virtual_root_path or [] + vroot_path = request.virtual_root_path or () view_name = request.view_name subpath = request.subpath or () - script_list = traversed[len(vroot_path):] - script_list = [ quote_path_segment(name) for name in script_list ] + script_tuple = traversed[len(vroot_path):] + script_list = [ quote_path_segment(name) for name in script_tuple ] if view_name: script_list.append(quote_path_segment(view_name)) script_name = '/' + '/'.join(script_list) -- cgit v1.2.3