Remove all deprecations from Action Pack #26746
Merged
Conversation
`skip_action_callback`, `skip_filter`, `before_filter`, `prepend_before_filter`, `skip_before_filter`, `append_before_filter`, `around_filter` `prepend_around_filter`, `skip_around_filter`, `append_around_filter`, `after_filter`, `prepend_after_filter`, `skip_after_filter` and `append_after_filter`.
ActionDispatch::ParamsParser class was removed in favor of ActionDispatch::Http::Parameters so it is better to move the error constant to the new class.
…outing::Mapper#match`
…s in `ActionDispatch::Routing::Mapper#match`
…::IntegrationTest`, `#process`, `#get`, `#post`, `#patch`, `#put`, `#delete`, and `#head`.
|
@@ -620,28 +611,8 @@ def init_with(coder) # :nodoc: | |||
end | |||
end | |||
|
|||
# Undefine `to_param` such that it gets caught in the `method_missing` | |||
# deprecation cycle below. | |||
undef_method :to_param |
kaspth
Oct 10, 2016
Member
Should we still undef this?
Should we still undef this?
rafaelfranca
Oct 10, 2016
Author
Member
I think so. The idea to undef this was to users not call to_param
on parameters expecting the hash behavior and getting the to_s
result. If we keep it defined it will silently break again and users will have the wrong behavior.
I think so. The idea to undef this was to users not call to_param
on parameters expecting the hash behavior and getting the to_s
result. If we keep it defined it will silently break again and users will have the wrong behavior.
kaspth
Oct 10, 2016
Member
👌
icyflame
added a commit
to icyflame/cutouts
that referenced
this pull request
Dec 28, 2019
- ActionPack removed the Hash-type methods from the Parameters type: - rails/rails#26746 - Visibility's conversion from string to integer for an enum model key does not work anymore. Not sure about the root cause for this one. Moved all logic to convert from parameters object to unsafe hash in the helper module.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
This the first pass through the codebase to remove deprecations. I chose to open a PR per component to avoid conflicts.
I only left one of the deprecations because I'm not entirely sure how we want to deal with them. The deprecation left is the one added in 6520ea5. @pixeltrix can you push the code that remove the deprecated code in a new branch? I can deal with the broken tests after you push it.
I'm planing to merged as soon the tests are green.