diff options
Diffstat (limited to 'activemodel/lib/active_model/serializers/json.rb')
-rw-r--r-- | activemodel/lib/active_model/serializers/json.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activemodel/lib/active_model/serializers/json.rb b/activemodel/lib/active_model/serializers/json.rb index c58e73f6a7..77f2a64b11 100644 --- a/activemodel/lib/active_model/serializers/json.rb +++ b/activemodel/lib/active_model/serializers/json.rb @@ -93,7 +93,7 @@ module ActiveModel end if root - root = self.class.model_name.element if root == true + root = model_name.element if root == true { root => serializable_hash(options) } else serializable_hash(options) |