'Normalize URLs.'

def process_request(self, request):

    if ((len(request.environ['PATH_INFO']) > 1) and (request.environ['PATH_INFO'][(-1)] == '/')):
        request.environ['PATH_INFO'] = request.environ['PATH_INFO'][:(-1)]
    elif (not request.environ['PATH_INFO']):
        request.environ['PATH_INFO'] = '/'
