Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Also need to deprecate engine= first. #41

Merged
merged 1 commit into from

2 participants

@arunagw

Just found that Rails test started failing today after new release. I am not sure that how we can go with this. But we need to deprecate engine= also.

https://github.com/rails/rails/blob/master/activesupport/lib/active_support/json/decoding.rb#L26

@arunagw

Closing this. As Rails is now using new API.

rails/rails#5860

@arunagw arunagw closed this
@arunagw arunagw reopened this
@arunagw

I have reopen this again. I think for 3.2.X release we can show warning.

@sferik sferik merged commit be020a3 into intridea:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 6 additions and 0 deletions.
  1. +6 −0 lib/multi_json.rb
View
6 lib/multi_json.rb
@@ -47,6 +47,12 @@ def engine
self.adapter
end
+ # TODO: Remove for 2.0 release (but no sooner)
+ def engine=(new_engine)
+ Kernel.warn "#{Kernel.caller.first}: [DEPRECATION] MultiJson.engine= is deprecated and will be removed in the next major version. Use MultiJson.use instead."
+ self.use(new_engine)
+ end
+
# Get the current adapter class.
def adapter
return @adapter if @adapter
Something went wrong with that request. Please try again.