From 169e524f46dc977363d4588ca62d63d09a4803e6 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 14 Jun 2024 12:11:34 -0400 Subject: [PATCH] Use params slice and uniq constant in admin::filter_helper --- app/helpers/admin/filter_helper.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/helpers/admin/filter_helper.rb b/app/helpers/admin/filter_helper.rb index 140fc73ede4..32f0d995961 100644 --- a/app/helpers/admin/filter_helper.rb +++ b/app/helpers/admin/filter_helper.rb @@ -15,7 +15,7 @@ module Admin::FilterHelper AnnouncementFilter::KEYS, Admin::ActionLogFilter::KEYS, Admin::StatusFilter::KEYS, - ].flatten.freeze + ].flatten.uniq.freeze def filter_link_to(text, link_to_params, link_class_params = link_to_params) new_url = filtered_url_for(link_to_params) @@ -48,6 +48,6 @@ module Admin::FilterHelper end def controller_request_params - params.permit(FILTERS) + params.slice(FILTERS).permit(FILTERS) end end