From 4b3c37bb79d03a8eda3a0594bc120a06311582d3 Mon Sep 17 00:00:00 2001 From: Iva Date: Fri, 27 Sep 2024 17:23:42 +0300 Subject: [PATCH] Fix scope again --- back/app/policies/cosponsorship_policy.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/back/app/policies/cosponsorship_policy.rb b/back/app/policies/cosponsorship_policy.rb index f38b90f399dd..f0ad364c4b03 100644 --- a/back/app/policies/cosponsorship_policy.rb +++ b/back/app/policies/cosponsorship_policy.rb @@ -10,7 +10,7 @@ def initialize(user, scope) end def resolve - scope.where(post_id: Pundit.policy_scope(user, Idea)) + scope.where(idea_id: Pundit.policy_scope(user, Idea)) end end