-
Notifications
You must be signed in to change notification settings - Fork 54
Open
Description
When calling get :action, params: { params: 'string' }, RouteSet#url_for is trying to merge! the inner params string into the params hash.
https://github.com/rails/rails/blob/main/actionpack/lib/action_dispatch/routing/route_set.rb#L826
I added a failing test here:
The issue came up while migrating to 6.1, looking into writing a failing spec directly in rails/rails, rather than through controller testing, but this one helped pinpoint the issue as it showed up in our code.
We could change RouteSet to check if options.key?(:params) && options[:params].is_a?(Hash) before attempting a merge, but maybe there's a better way?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels