small cleanup stuff

This commit is contained in:
David Goetz
2010-11-01 15:13:38 -07:00
parent 1f09bb6720
commit d722a2884e
2 changed files with 5 additions and 6 deletions

View File

@@ -517,8 +517,7 @@ YOU HAVE A FEW OPTIONS:
:param request: A webob.Request instance. :param request: A webob.Request instance.
""" """
try: try:
pathsegs = \ pathsegs = split_path(request.path, minsegs=1, maxsegs=3,
split_path(request.path, minsegs=1, maxsegs=3,
rest_with_last=True) rest_with_last=True)
except ValueError: except ValueError:
return HTTPBadRequest() return HTTPBadRequest()

View File

@@ -85,7 +85,7 @@ class DevAuth(object):
try: try:
version, rest = split_path(env.get('PATH_INFO', ''), version, rest = split_path(env.get('PATH_INFO', ''),
1, 2, True) 1, 2, True)
except ValueError, err: except ValueError:
return HTTPNotFound()(env, start_response) return HTTPNotFound()(env, start_response)
if rest and rest.startswith(self.reseller_prefix): if rest and rest.startswith(self.reseller_prefix):
# Handle anonymous access to accounts I'm the definitive # Handle anonymous access to accounts I'm the definitive