This is happening probably because projects is not an attribute of the model and you haven't added 'projects'
to the $appends
property of your model. http://laravel.com/docs/eloquent#converting-to-arrays-or-json (near the end)
UPDATE:
The problem was happening because of the method attributesToArray
not handling instances of ArrayableInterface
. A method override has been provided in the comments of this answer, and a relevant patch has been merged to laravel 4.1