{"action":"opened","issue":{"url":"https://api.github.com/repos/dunglas/api-platform/issues/1","labels_url":"https://api.github.com/repos/dunglas/api-platform/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/dunglas/api-platform/issues/1/comments","events_url":"https://api.github.com/repos/dunglas/api-platform/issues/1/events","html_url":"https://github.com/dunglas/api-platform/issues/1","id":72619961,"number":1,"title":"Nitpicking: array_search with ArrayCollection","user":{"login":"theofidry","id":5175937,"avatar_url":"https://avatars.githubusercontent.com/u/5175937?v=3","gravatar_id":"","url":"https://api.github.com/users/theofidry","html_url":"https://github.com/theofidry","followers_url":"https://api.github.com/users/theofidry/followers","following_url":"https://api.github.com/users/theofidry/following{/other_user}","gists_url":"https://api.github.com/users/theofidry/gists{/gist_id}","starred_url":"https://api.github.com/users/theofidry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theofidry/subscriptions","organizations_url":"https://api.github.com/users/theofidry/orgs","repos_url":"https://api.github.com/users/theofidry/repos","events_url":"https://api.github.com/users/theofidry/events{/privacy}","received_events_url":"https://api.github.com/users/theofidry/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-02T09:30:33Z","updated_at":"2015-05-02T09:30:33Z","closed_at":null,"body":"It may works fine but I still get a warning in my IDE with:\r\n\r\n```\r\npublic function removeIllustrator(Person $illustrator)\r\n{\r\n    $key = array_search($illustrator, $this->illustrator, true);\r\n    if (false !== $key) {\r\n        unset($this->illustrator[$key]);\r\n    }\r\n    return $this;\r\n}\r\n```\r\n\r\nChanging `$this->illustrator` to `$this->illustrator->toArray()` solves the problem."}}