From 6f92548b38ab1f651b20b4b0696f0aee28eb430b Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Fri, 24 Oct 2014 02:18:45 +0000 Subject: remove unneeded "references" of joins "references" is needed for includes, but not needed for joins. git-svn-id: http://svn.redmine.org/redmine/trunk@13501 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/models/issue_query.rb | 1 - 1 file changed, 1 deletion(-) (limited to 'app/models/issue_query.rb') diff --git a/app/models/issue_query.rb b/app/models/issue_query.rb index 9ca0f3077..15c49c5d6 100644 --- a/app/models/issue_query.rb +++ b/app/models/issue_query.rb @@ -46,7 +46,6 @@ class IssueQuery < Query user = args.shift || User.current base = Project.allowed_to_condition(user, :view_issues, *args) scope = joins("LEFT OUTER JOIN #{Project.table_name} ON #{table_name}.project_id = #{Project.table_name}.id"). - references(:project). where("#{table_name}.project_id IS NULL OR (#{base})") if user.admin? -- cgit v1.2.3