From: Mark McLoughlin Date: Tue, 17 Jul 2012 03:18:40 +0000 (+0100) Subject: Remove unused wrap_errors decorator X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=c73d15d347ba5a973e257932ffb9d6012939e3a5;p=openstack-build%2Fcinder-build.git Remove unused wrap_errors decorator Only used by rescue extension in nova. Change-Id: I3ade99405736bf8ffb8891a8d53c02905501ae44 --- diff --git a/cinder/api/openstack/extensions.py b/cinder/api/openstack/extensions.py index baa9510b6..c7bce4b83 100644 --- a/cinder/api/openstack/extensions.py +++ b/cinder/api/openstack/extensions.py @@ -297,18 +297,6 @@ class ResourceExtension(object): self.custom_routes_fn = custom_routes_fn -def wrap_errors(fn): - """Ensure errors are not passed along.""" - def wrapped(*args, **kwargs): - try: - return fn(*args, **kwargs) - except webob.exc.HTTPException: - raise - except Exception: - raise webob.exc.HTTPInternalServerError() - return wrapped - - def load_standard_extensions(ext_mgr, logger, path, package, ext_list=None): """Registers all standard API extensions."""