From b5d47b18f1026c0393265050199282c7b832f5f1 Mon Sep 17 00:00:00 2001 From: Srinivas Reddy Thatiparthy Date: Tue, 8 Aug 2017 07:31:45 +0530 Subject: [PATCH] Removed unnecessary else in SelectDateWidget.id_for_lable(). --- django/forms/widgets.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/django/forms/widgets.py b/django/forms/widgets.py index 93f831e6cc..4bbe6ce052 100644 --- a/django/forms/widgets.py +++ b/django/forms/widgets.py @@ -1036,8 +1036,7 @@ class SelectDateWidget(Widget): def id_for_label(self, id_): for first_select in self._parse_date_fmt(): return '%s_%s' % (id_, first_select) - else: - return '%s_month' % id_ + return '%s_month' % id_ def value_from_datadict(self, data, files, name): y = data.get(self.year_field % name)