aboutsummaryrefslogtreecommitdiffstats
path: root/djangorestframework/utils
diff options
context:
space:
mode:
Diffstat (limited to 'djangorestframework/utils')
-rw-r--r--djangorestframework/utils/__init__.py2
-rw-r--r--djangorestframework/utils/breadcrumbs.py2
-rw-r--r--djangorestframework/utils/mediatypes.py2
3 files changed, 3 insertions, 3 deletions
diff --git a/djangorestframework/utils/__init__.py b/djangorestframework/utils/__init__.py
index 305311f4..2b4fd10e 100644
--- a/djangorestframework/utils/__init__.py
+++ b/djangorestframework/utils/__init__.py
@@ -43,7 +43,7 @@ def url_resolves(url):
"""
try:
resolve(url)
- except:
+ except Exception:
return False
return True
diff --git a/djangorestframework/utils/breadcrumbs.py b/djangorestframework/utils/breadcrumbs.py
index 6cf978ed..fd966282 100644
--- a/djangorestframework/utils/breadcrumbs.py
+++ b/djangorestframework/utils/breadcrumbs.py
@@ -11,7 +11,7 @@ def get_breadcrumbs(url):
try:
(view, unused_args, unused_kwargs) = resolve(url)
- except:
+ except Exception:
pass
else:
# Check if this is a REST framework view, and if so add it to the breadcrumbs
diff --git a/djangorestframework/utils/mediatypes.py b/djangorestframework/utils/mediatypes.py
index 3c0eefc4..c0071f01 100644
--- a/djangorestframework/utils/mediatypes.py
+++ b/djangorestframework/utils/mediatypes.py
@@ -109,7 +109,7 @@ class _MediaType(object):
# """
# try:
# return Decimal(self.params.get('q', '1.0'))
- # except:
+ # except Exception:
# return Decimal(0)
#def score(self):