summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndriy Sokolovskiy <me@asokolovskiy.com>2015-06-29 23:29:18 +0300
committerTim Graham <timograham@gmail.com>2015-06-29 17:14:29 -0400
commit4359be023be3f5e5a1d1d89bf8f193d15f49b7a4 (patch)
tree85750793d5bc2911898abf1a65d6693ebd6e90ea
parentaef2a0ec59301022354c043744a6a2fa13583aa1 (diff)
Removed unreachable code
-rw-r--r--django/contrib/admin/checks.py9
-rw-r--r--django/template/loader.py1
2 files changed, 0 insertions, 10 deletions
diff --git a/django/contrib/admin/checks.py b/django/contrib/admin/checks.py
index 8788fd108d..15a2719777 100644
--- a/django/contrib/admin/checks.py
+++ b/django/contrib/admin/checks.py
@@ -776,15 +776,6 @@ class ModelAdminChecks(BaseModelAdminChecks):
if field_name not in cls.list_display:
return refer_to_missing_field(field=field_name, option=label,
model=model, obj=cls, id='admin.E122')
-
- checks.Error(
- "The value of '%s' refers to '%s', which is not contained in 'list_display'." % (
- label, field_name
- ),
- hint=None,
- obj=cls,
- id='admin.E122',
- ),
elif cls.list_display_links and field_name in cls.list_display_links:
return [
checks.Error(
diff --git a/django/template/loader.py b/django/template/loader.py
index ccc13f96c1..ed3039b471 100644
--- a/django/template/loader.py
+++ b/django/template/loader.py
@@ -104,7 +104,6 @@ def render_to_string(template_name, context=None,
raise ValueError(
"render_to_string doesn't support the request argument "
"when some deprecated arguments are passed.")
- continue
# Hack -- use the internal Engine instance of DjangoTemplates.
return engine.engine.render_to_string(
template_name, context, context_instance, dirs, dictionary)