summaryrefslogtreecommitdiff
path: root/django/forms
diff options
context:
space:
mode:
authorCollin Anderson <cmawebsite@gmail.com>2017-02-20 08:48:03 -0500
committerTim Graham <timograham@gmail.com>2017-02-20 08:48:17 -0500
commit808d33c1bf15e6fba38b361e47c60a0b8208b2e0 (patch)
tree910f58bfd825b66a021fdfd76442b195e5628d23 /django/forms
parent447c6802f0a19d62026f2a8c84a479377ce80b20 (diff)
[1.11.x] Fixed #27850 -- Made RelatedFieldWidgetWrapper call render() of the wrapped widget.
Backport of fb7e0e01af5364987de7fc95ae4d66e22130f2bc from master
Diffstat (limited to 'django/forms')
-rw-r--r--django/forms/widgets.py8
1 files changed, 0 insertions, 8 deletions
diff --git a/django/forms/widgets.py b/django/forms/widgets.py
index aca599ff9a..82efdef633 100644
--- a/django/forms/widgets.py
+++ b/django/forms/widgets.py
@@ -7,7 +7,6 @@ from __future__ import unicode_literals
import copy
import datetime
import re
-from contextlib import contextmanager
from itertools import chain
from django.conf import settings
@@ -647,13 +646,6 @@ class ChoiceWidget(Widget):
pass
return getter(name)
- @contextmanager
- def override_choices(self, choices):
- old = self.choices
- self.choices = choices
- yield
- self.choices = old
-
def format_value(self, value):
"""Return selected values as a set."""
if not isinstance(value, (tuple, list)):