From ec40b4f7fb48da213cdfac57a9206228b0d6fb16 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Tue, 16 Nov 2021 09:59:52 -0500 Subject: [PATCH] Fixing comment report creator. Fixes #1904 --- crates/db_views/src/comment_report_view.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/db_views/src/comment_report_view.rs b/crates/db_views/src/comment_report_view.rs index 1469e42d..5b39a5eb 100644 --- a/crates/db_views/src/comment_report_view.rs +++ b/crates/db_views/src/comment_report_view.rs @@ -80,7 +80,7 @@ impl CommentReportView { .inner_join(post::table.on(comment::post_id.eq(post::id))) .inner_join(community::table.on(post::community_id.eq(community::id))) .inner_join(person::table.on(comment_report::creator_id.eq(person::id))) - .inner_join(person_alias_1::table.on(post::creator_id.eq(person_alias_1::id))) + .inner_join(person_alias_1::table.on(comment::creator_id.eq(person_alias_1::id))) .inner_join( comment_aggregates::table.on(comment_report::comment_id.eq(comment_aggregates::comment_id)), ) @@ -215,7 +215,7 @@ impl<'a> CommentReportQueryBuilder<'a> { .inner_join(post::table.on(comment::post_id.eq(post::id))) .inner_join(community::table.on(post::community_id.eq(community::id))) .inner_join(person::table.on(comment_report::creator_id.eq(person::id))) - .inner_join(person_alias_1::table.on(post::creator_id.eq(person_alias_1::id))) + .inner_join(person_alias_1::table.on(comment::creator_id.eq(person_alias_1::id))) // Test this join .inner_join( community_moderator::table.on(community_moderator::community_id.eq(post::community_id)), -- 2.44.1