Split up the logic, and make the parser smarter

We now inspect the content object returned and see if it is an object containing many objects, or a single object.