Used "is" for comparisons with None.

This commit is contained in:
Tim Graham 2013-10-10 09:35:56 -04:00
parent ff9e8eccf8
commit cec11a3336
8 changed files with 17 additions and 16 deletions

View file

@ -508,7 +508,7 @@ class Select(Widget):
return mark_safe('\n'.join(output))
def render_option(self, selected_choices, option_value, option_label):
if option_value == None:
if option_value is None:
option_value = ''
option_value = force_text(option_value)
if option_value in selected_choices: