mirror of
https://github.com/django/django.git
synced 2025-11-07 07:15:35 +00:00
Fixed #27256 -- Changed Select widget's selected attribute to use HTML5 boolean syntax.
This commit is contained in:
@@ -544,7 +544,7 @@ class Select(Widget):
|
||||
option_value = ''
|
||||
option_value = force_text(option_value)
|
||||
if option_value in selected_choices:
|
||||
selected_html = mark_safe(' selected="selected"')
|
||||
selected_html = mark_safe(' selected')
|
||||
if not self.allow_multiple_selected:
|
||||
# Only allow for a single selection.
|
||||
selected_choices.remove(option_value)
|
||||
|
||||
Reference in New Issue
Block a user