From 33bfba71042a55ff57115e833aabfed9852e80f4 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Thu, 20 Sep 2012 09:31:27 -0500 Subject: Defer content and other text items when building news sitemap We can get away with not retrieving these larger pieces of data when building the news sitemap. Signed-off-by: Dan McGee --- sitemaps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sitemaps.py') diff --git a/sitemaps.py b/sitemaps.py index 97ab43c0..b53c990b 100644 --- a/sitemaps.py +++ b/sitemaps.py @@ -66,7 +66,7 @@ def __init__(self): self.one_week_ago = now - timedelta(days=7) def items(self): - return News.objects.all().order_by() + return News.objects.all().defer('content', 'guid', 'title').order_by() def lastmod(self, obj): return obj.last_modified -- cgit v1.2.3-54-g00ecf