laravel/framework — pull request #4301 by kapv89 (2014-05-01 20:03:13+00:00)
Title: `attributesToArray` can handle instances of `ArrayableInterface`

basically some mutators can return instances of `ArrayableInterface`, and this case is not handled by `attributesToArray`, so put that condition in there