Commit d9c36084 by mjparker777

changed datefield to match code layout of datetime and time changes

parent f3d5e148
......@@ -1121,11 +1121,11 @@ class DateField(Field):
self.fail('invalid', format=humanized_format)
def to_representation(self, value):
output_format = getattr(self, 'format', api_settings.DATE_FORMAT)
if not value:
return None
output_format = getattr(self, 'format', api_settings.DATE_FORMAT)
if output_format is None:
return value
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment