From 58defcbc50caa2bd1c2f970b03bdf1df2cb57df8 Mon Sep 17 00:00:00 2001 From: Michel Felipe de Oliveira Ferreira Date: Mon, 13 Jul 2015 16:16:36 -0300 Subject: [PATCH] Fix the save_categories action permission in ProposalTasksController --- controllers/myprofile/proposals_discussion_plugin_tasks_controller.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/controllers/myprofile/proposals_discussion_plugin_tasks_controller.rb b/controllers/myprofile/proposals_discussion_plugin_tasks_controller.rb index 31b9641..9b58da7 100644 --- a/controllers/myprofile/proposals_discussion_plugin_tasks_controller.rb +++ b/controllers/myprofile/proposals_discussion_plugin_tasks_controller.rb @@ -1,7 +1,11 @@ class ProposalsDiscussionPluginTasksController < TasksController + protect [:perform_task, :view_tasks], :profile, :only => [:index, :save_tags, :search_tags, :save_categories] + protect :perform_task, :profile, :except => [:index, :save_tags, :search_tags, :save_categories] + def index - @email_templates = profile.email_templates.find_all_by_template_type(:task_rejection) + @rejection_email_templates = profile.email_templates.find_all_by_template_type(:task_rejection) + @acceptance_email_templates = profile.email_templates.find_all_by_template_type(:task_acceptance) @filter_type = params[:filter_type].presence @filter_text = params[:filter_text].presence -- libgit2 0.21.2