Ensure the adapters honor a custom root option and include meta when required

This commit is contained in:
Chris Branson
2015-06-03 09:01:51 +01:00
parent 35fb9de310
commit d34bba07b9
4 changed files with 75 additions and 8 deletions

View File

@@ -75,7 +75,7 @@ module ActiveModel
end
def root
serializer.json_key
@options.fetch(:root) { serializer.json_key }
end
def include_meta(json)