Closed
Description
Hello,
I was trying to make a doctrine entity -> json conversion work with the Serializer bundle, I was following both http://symfony.com/doc/current/components/serializer.html and http://jmsyst.com/libs/serializer#usage . The code mentions several times this:
$serializer->serialize($person, 'json'); or more generally, this: $serializer->serialize($data, 'json'); .
It seems that in order for it to work, you need to
$avariable = $serializer->serialize($data, 'json'); and return that $avariable in the response.
I understand it might seem trivial for PHP-ers but as it's a guide for people starting up, why not add a line with the proper return response? (would save time:))
Thanks!