From ed370209b87a290dc85fc8b85e9070db40c3668f Mon Sep 17 00:00:00 2001 From: Deimos Date: Tue, 6 Aug 2019 11:13:53 -0600 Subject: [PATCH] Fix repost check not using TopicQuery This was making it include deleted/removed posts. --- tildes/tildes/views/topic.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tildes/tildes/views/topic.py b/tildes/tildes/views/topic.py index 6a33071..d739268 100644 --- a/tildes/tildes/views/topic.py +++ b/tildes/tildes/views/topic.py @@ -61,7 +61,7 @@ def post_group_topics( if link: # check to see if this link has been posted before previous_topics = ( - request.db_session.query(Topic) + request.query(Topic) .filter(Topic.link == link) .order_by(desc(Topic.created_time)) .limit(5)