Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

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
Adrian Holovaty authored

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. 2  django/db/models/__init__.py
2  django/db/models/__init__.py
@@ -47,7 +47,7 @@ def __repr__(self):
47 47
         return "<LazyDate: %s>" % self.delta
48 48
 
49 49
     def __get_value__(self):
50  
-        return datetime.datetime.now() + self.delta
  50
+        return (datetime.datetime.now() + self.delta).date()
51 51
 
52 52
     def __getattr__(self, attr):
53 53
         return getattr(self.__get_value__(), attr)

0 notes on commit 54ea309

Please sign in to comment.
Something went wrong with that request. Please try again.