Skip to content

Commit

Permalink
Compatible multi_json >= 1.0.0 with Rails3.2.8
Browse files Browse the repository at this point in the history
  • Loading branch information
sanemat committed Oct 10, 2012
1 parent 0903702 commit 92a074b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/compat/multi_json.rb
@@ -1,7 +1,7 @@
gem 'multi_json', '>= 1.0.0'
require 'multi_json'

if !MultiJson.respond_to?(:load) || MultiJson.method(:load).owner == Kernel
if !MultiJson.respond_to?(:load) || [Kernel, ActiveSupport::Dependencies::Loadable].include?(MultiJson.method(:load).owner)

This comment has been minimized.

Copy link
@sporkmonger

sporkmonger Oct 12, 2012

This will probably cause NameError exceptions if ActiveSupport isn't loaded.

module MultiJson
class <<self
alias :load :decode
Expand Down

0 comments on commit 92a074b

Please sign in to comment.