From c1dfdfaed4973b87998cefa64f6b90b8286991b7 Mon Sep 17 00:00:00 2001 From: Jorge Manrubia Date: Tue, 6 May 2025 15:23:31 +0200 Subject: [PATCH] Fix test --- app/models/command/parser/context.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/command/parser/context.rb b/app/models/command/parser/context.rb index 19ddc883d..770477963 100644 --- a/app/models/command/parser/context.rb +++ b/app/models/command/parser/context.rb @@ -15,7 +15,7 @@ class Command::Parser::Context end def filter - user.filters.from_params(params.slice(*Filter::Params::PERMITTED_PARAMS).reverse_merge(**FilterScoped::DEFAULT_PARAMS)) + user.filters.from_params(params.permit(*Filter::Params::PERMITTED_PARAMS).reverse_merge(**FilterScoped::DEFAULT_PARAMS)) end private @@ -26,6 +26,6 @@ class Command::Parser::Context route = Rails.application.routes.recognize_path(uri.path) @controller = route[:controller] @action = route[:action] - @params = Rack::Utils.parse_nested_query(uri.query).merge(route.except(:controller, :action)) + @params = ActionController::Parameters.new(Rack::Utils.parse_nested_query(uri.query).merge(route.except(:controller, :action))) end end