From 72aa21c9cd66dbaba0973e92fd36d18431b8c490 Mon Sep 17 00:00:00 2001 From: Untone Date: Fri, 23 Feb 2024 13:34:31 +0300 Subject: [PATCH] get-topic-fix --- resolvers/stat.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resolvers/stat.py b/resolvers/stat.py index d0e7e0bc..d725cdbe 100644 --- a/resolvers/stat.py +++ b/resolvers/stat.py @@ -16,7 +16,7 @@ def add_topic_stat_columns(q): .add_columns(func.count(distinct(ShoutTopic.shout)).label('shouts_stat')) .outerjoin(aliased_shout_authors, ShoutTopic.shout == aliased_shout_authors.shout) .add_columns(func.count(distinct(aliased_shout_authors.author)).label('authors_stat')) - .outerjoin(aliased_topic_followers, aliased_topic_followers.topic == aliased_topic.id) + .outerjoin(aliased_topic_followers, aliased_topic.id == aliased_topic_followers.topic) .add_columns(func.count(distinct(aliased_topic_followers.follower)).label('followers_stat')) )