From 54ea309a1d0d10b1ff67aba582c1eaf4a1784d02 Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Sat, 12 Aug 2006 05:18:25 +0000 Subject: [PATCH] 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 --- django/db/models/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/db/models/__init__.py b/django/db/models/__init__.py index eac7758055..0308dd047a 100644 --- a/django/db/models/__init__.py +++ b/django/db/models/__init__.py @@ -47,7 +47,7 @@ class LazyDate(object): return "" % 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)