Skip to content
Browse files

Merge pull request #41 from arunagw/master

Also need to deprecate engine= first.
  • Loading branch information...
2 parents d05c613 + 9d85fa6 commit be020a31470669d4260afec627847c27dd97c54a @sferik sferik committed Apr 16, 2012
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

0 comments on commit be020a3

Please sign in to comment.
Something went wrong with that request. Please try again.