From 7bf5fab1fa2fa07cc012c0570781aea23343ae05 Mon Sep 17 00:00:00 2001 From: ketralnis Date: Tue, 1 Jul 2008 17:38:48 -0700 Subject: [PATCH] Bug #14, Duplicates in RSS Adds request.host to the cache key http://code.reddit.com/ticket/14 --- r2/r2/models/link.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/r2/r2/models/link.py b/r2/r2/models/link.py index e1d580e08..8fb1d758e 100644 --- a/r2/r2/models/link.py +++ b/r2/r2/models/link.py @@ -31,7 +31,7 @@ from r2.lib.db.operators import lower, base_url from mako.filters import url_escape from r2.lib.strings import strings, Score -from pylons import c, g +from pylons import c, g, request from pylons.i18n import ungettext import random @@ -191,6 +191,7 @@ class Link(Thing, Printable): c.user.pref_newwindow, c.user.pref_frame, c.user.pref_compress, + request.host, wrapped.author == c.user, wrapped.likes, wrapped.saved, @@ -316,6 +317,7 @@ class Comment(Thing, Printable): self._fullname, bool(c.user_is_loggedin), c.focal_comment == self._id36, + request.host, wrapped.author == c.user, wrapped.likes, wrapped.friend,