Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Soft-deprecate the HashWithIndifferentAccess constant #28157

Merged
merged 2 commits into from Feb 25, 2017
Merged

Soft-deprecate the HashWithIndifferentAccess constant #28157

merged 2 commits into from Feb 25, 2017

Conversation

robin850
Copy link
Member

Hi,

That's just a second take on #27925. This version just softly deprecates the top-level HashWithIndifferentAccess constant rather than trying to display a deprecation message since this constant and the ActiveSupport-scoped one are exactly the same which means that changing one inevitably changes the other.

PS : Even though it's not yet posted, I took the liberty to add the link to the 5.1 release notes in the upgrade guides to avoid missing it writing the other steps of the upgrade process.

Have a nice day ! :-)

Since using a `ActiveSupport::Deprecation::DeprecatedConstantProxy`
would prevent people from inheriting this class and extending it
from the `ActiveSupport::HashWithIndifferentAccess` one would break
the ancestors chain, that's the best option we have here.
This ensures that if we try to hard-deprecate it again in the future,
we won't break these behaviors.
@matthewd matthewd merged commit ac57a3e into rails:master Feb 25, 2017
matthewd added a commit that referenced this pull request Feb 25, 2017
Soft-deprecate the `HashWithIndifferentAccess` constant
@robin850 robin850 deleted the hwia-soft-deprecation branch February 25, 2017 00:27
@@ -1,3 +1,9 @@
* Soft-deprecated the top-level `HashWithIndifferentAcces` constant.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo on HashWithIndifferentAcces

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in dd3adc5.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants