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

Do not override Object#to_json with mimic_json if ActiveSupport is existed #936

Merged
merged 7 commits into from
Aug 18, 2024

Conversation

Watson1978
Copy link
Collaborator

Fix #934

@Watson1978 Watson1978 marked this pull request as draft August 18, 2024 13:58
@Watson1978 Watson1978 marked this pull request as ready for review August 18, 2024 14:40
@Watson1978 Watson1978 changed the title Do not override Object#to_json with mimic_json Do not override Object#to_json with mimic_json if ActiveSupport is existed Aug 18, 2024
@ohler55 ohler55 merged commit 2570138 into ohler55:develop Aug 18, 2024
61 checks passed
@Watson1978 Watson1978 deleted the rails7.2 branch August 18, 2024 14:54
@@ -19,7 +19,10 @@
Thread.abort_on_exception = true

# Show backtraces for deprecated behavior for quicker cleanup.
ActiveSupport::Deprecation.debug = true
if ActiveSupport::Deprecation.respond_to?(:debug)
# Rails 7.2 does not have ActiveSupport::Deprecation.debug

Choose a reason for hiding this comment

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

@ohler55 & @Watson1978 , for Rails 7.2 I think you want to call:

ActiveSupport.deprecator.debug = true

Each module in Rails has its own deprecator instance now: rails/rails@e5af9c2

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

Successfully merging this pull request may close these issues.

#as_json ignored on Rails 7.2.0
3 participants