From e97a3ab97bfa62ac173ca8773e22bb3d33d7f22f Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sun, 2 Dec 2012 10:25:30 +0000 Subject: [PATCH] Fixed find_issues logic. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10905 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/controllers/application_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 05a4b87fa..585ac5788 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -293,7 +293,7 @@ class ApplicationController < ActionController::Base def find_issues @issues = Issue.find_all_by_id(params[:id] || params[:ids]) raise ActiveRecord::RecordNotFound if @issues.empty? - raise Unauthorized if @issues.all?(&:visible?) + raise Unauthorized unless @issues.all?(&:visible?) @projects = @issues.collect(&:project).compact.uniq @project = @projects.first if @projects.size == 1 rescue ActiveRecord::RecordNotFound -- 2.39.5