Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #2513 -- Changed LazyDate.__get_value__() to return date object…

…s, not datetime objects

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3566 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 54ea309a1d0d10b1ff67aba582c1eaf4a1784d02 1 parent 9cd0c33
@adrianholovaty adrianholovaty authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/db/models/__init__.py
View
2  django/db/models/__init__.py
@@ -47,7 +47,7 @@ def __repr__(self):
return "<LazyDate: %s>" % self.delta
def __get_value__(self):
- return datetime.datetime.now() + self.delta
+ return (datetime.datetime.now() + self.delta).date()
def __getattr__(self, attr):
return getattr(self.__get_value__(), attr)
Please sign in to comment.
Something went wrong with that request. Please try again.