Fixed #2513 -- Changed LazyDate.__get_value__() to return date objects, not datetime objects
git-svn-id: http://code.djangoproject.com/svn/django/trunk@3566 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
9cd0c333d6
commit
54ea309a1d
|
@ -47,7 +47,7 @@ class LazyDate(object):
|
|||
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)
|
||||
|
|
Loading…
Reference in New Issue