Removed unnecessary microsecond truncation in SplitDateTimeWidget.

The microseconds are already truncated by the TimeInput subwidget.
This commit is contained in:
Jon Dufresne 2018-01-18 08:23:06 -08:00 committed by Tim Graham
parent 3c34452ab5
commit 90ca9412e4
2 changed files with 2 additions and 2 deletions

View File

@ -888,7 +888,7 @@ class SplitDateTimeWidget(MultiWidget):
def decompress(self, value):
if value:
value = to_current_timezone(value)
return [value.date(), value.time().replace(microsecond=0)]
return [value.date(), value.time()]
return [None, None]

View File

@ -359,7 +359,7 @@ foundation for custom widgets.
def decompress(self, value):
if value:
return [value.date(), value.time().replace(microsecond=0)]
return [value.date(), value.time()]
return [None, None]
.. tip::