README.md in jsonapi_mapper-0.1.2 vs README.md in jsonapi_mapper-0.1.3
- old
+ new
@@ -69,16 +69,15 @@
people: [:name, :pet, :parent, :children, country: 'argentina'],
pet_dogs: [:name, country: 'argentina']
)
# The document data lives in mapper.data
- # It's always an array, even if the document had a single resource.
+ # It could be a simple or multiple resource response.
# If you want to check wether the document had a single resource
# or a collection as its primary data you can use the following methods.
mapper.collection? # Was primary document data a collection?
mapper.single? # Was primary document data a single resource?
- person = mapper.data.first
# The rest of the included resources live in mapper.included
others = mapper.included
# Attempts to save both data and included. Returns false if there