{"action":"created","issue":{"url":"https://api.github.com/repos/laravel/internals/issues/45","repository_url":"https://api.github.com/repos/laravel/internals","labels_url":"https://api.github.com/repos/laravel/internals/issues/45/labels{/name}","comments_url":"https://api.github.com/repos/laravel/internals/issues/45/comments","events_url":"https://api.github.com/repos/laravel/internals/issues/45/events","html_url":"https://github.com/laravel/internals/issues/45","id":146727640,"number":45,"title":"Eloquent ArrayAccess","user":{"login":"lagbox","id":3752215,"avatar_url":"https://avatars.githubusercontent.com/u/3752215?v=3","gravatar_id":"","url":"https://api.github.com/users/lagbox","html_url":"https://github.com/lagbox","followers_url":"https://api.github.com/users/lagbox/followers","following_url":"https://api.github.com/users/lagbox/following{/other_user}","gists_url":"https://api.github.com/users/lagbox/gists{/gist_id}","starred_url":"https://api.github.com/users/lagbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lagbox/subscriptions","organizations_url":"https://api.github.com/users/lagbox/orgs","repos_url":"https://api.github.com/users/lagbox/repos","events_url":"https://api.github.com/users/lagbox/events{/privacy}","received_events_url":"https://api.github.com/users/lagbox/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-04-07T20:01:27Z","updated_at":"2016-04-07T21:59:42Z","closed_at":null,"body":"Can we adjust this to use the attributes only?\r\n\r\nI don't think people expect this to return properties if they exist and has caused a few people to run into issues with property names that match attribute names. Especially because of how `Arr::get` and other functions work, since it will use the model as an array not as an object, which means it will return a property value not an attribute's value if a property exists."},"comment":{"url":"https://api.github.com/repos/laravel/internals/issues/comments/207108179","html_url":"https://github.com/laravel/internals/issues/45#issuecomment-207108179","issue_url":"https://api.github.com/repos/laravel/internals/issues/45","id":207108179,"user":{"login":"tomschlick","id":70184,"avatar_url":"https://avatars.githubusercontent.com/u/70184?v=3","gravatar_id":"","url":"https://api.github.com/users/tomschlick","html_url":"https://github.com/tomschlick","followers_url":"https://api.github.com/users/tomschlick/followers","following_url":"https://api.github.com/users/tomschlick/following{/other_user}","gists_url":"https://api.github.com/users/tomschlick/gists{/gist_id}","starred_url":"https://api.github.com/users/tomschlick/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tomschlick/subscriptions","organizations_url":"https://api.github.com/users/tomschlick/orgs","repos_url":"https://api.github.com/users/tomschlick/repos","events_url":"https://api.github.com/users/tomschlick/events{/privacy}","received_events_url":"https://api.github.com/users/tomschlick/received_events","type":"User","site_admin":false},"created_at":"2016-04-07T21:59:42Z","updated_at":"2016-04-07T21:59:42Z","body":"It would also have to account for the \"appends\" logic but I agree it shouldn't include public vars on the model. Didn't even know that was a thing...\r\n\r\n\r\nhttps://laravel.com/docs/master/eloquent-serialization#appending-values-to-json"}}