{"action":"created","issue":{"url":"https://api.github.com/repos/php-fig/fig-standards/issues/494","labels_url":"https://api.github.com/repos/php-fig/fig-standards/issues/494/labels{/name}","comments_url":"https://api.github.com/repos/php-fig/fig-standards/issues/494/comments","events_url":"https://api.github.com/repos/php-fig/fig-standards/issues/494/events","html_url":"https://github.com/php-fig/fig-standards/pull/494","id":67016520,"number":494,"title":"Alternative way to address consistency issues mentioned in #491 and #493","user":{"login":"pjdietz","id":1231859,"avatar_url":"https://avatars.githubusercontent.com/u/1231859?v=3","gravatar_id":"","url":"https://api.github.com/users/pjdietz","html_url":"https://github.com/pjdietz","followers_url":"https://api.github.com/users/pjdietz/followers","following_url":"https://api.github.com/users/pjdietz/following{/other_user}","gists_url":"https://api.github.com/users/pjdietz/gists{/gist_id}","starred_url":"https://api.github.com/users/pjdietz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pjdietz/subscriptions","organizations_url":"https://api.github.com/users/pjdietz/orgs","repos_url":"https://api.github.com/users/pjdietz/repos","events_url":"https://api.github.com/users/pjdietz/events{/privacy}","received_events_url":"https://api.github.com/users/pjdietz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":45,"created_at":"2015-04-07T23:58:04Z","updated_at":"2015-04-08T20:19:28Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/php-fig/fig-standards/pulls/494","html_url":"https://github.com/php-fig/fig-standards/pull/494","diff_url":"https://github.com/php-fig/fig-standards/pull/494.diff","patch_url":"https://github.com/php-fig/fig-standards/pull/494.patch"},"body":"Another variant of PR #491 and #493 with specific return types.\r\n\r\nThis PR suggests the following changes:\r\n\r\n- `getHeader($name)` takes the place of the current `getHeaderLines($name)` and returns an array of strings (even with only one).\r\n- `getHeaders()` is unchanged and returns an array with arrays of strings for values.\r\n- `getHeaderLine($name)` takes the place of the current `getHeader($name)` and returns a (concatenated) string.\r\n- `getHeaderLines()` returns an array with strings as values.\r\n\r\nThis provides a predictable interface where the user can know the return type in advance and won't need to test whether the method returned a string or array.\r\n\r\nIt also adds consistency where both:\r\n\r\n```\r\n$message->getHeaders()[$k] === $message->getHeader($k)\r\n```\r\n\r\nAnd\r\n\r\n```\r\n$message->getHeaderLines()[$k] === $message->getHeaderLine($k)\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/php-fig/fig-standards/issues/comments/91024992","html_url":"https://github.com/php-fig/fig-standards/pull/494#issuecomment-91024992","issue_url":"https://api.github.com/repos/php-fig/fig-standards/issues/494","id":91024992,"user":{"login":"pmjones","id":25754,"avatar_url":"https://avatars.githubusercontent.com/u/25754?v=3","gravatar_id":"","url":"https://api.github.com/users/pmjones","html_url":"https://github.com/pmjones","followers_url":"https://api.github.com/users/pmjones/followers","following_url":"https://api.github.com/users/pmjones/following{/other_user}","gists_url":"https://api.github.com/users/pmjones/gists{/gist_id}","starred_url":"https://api.github.com/users/pmjones/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pmjones/subscriptions","organizations_url":"https://api.github.com/users/pmjones/orgs","repos_url":"https://api.github.com/users/pmjones/repos","events_url":"https://api.github.com/users/pmjones/events{/privacy}","received_events_url":"https://api.github.com/users/pmjones/received_events","type":"User","site_admin":false},"created_at":"2015-04-08T20:19:28Z","updated_at":"2015-04-08T20:19:28Z","body":"FWIW #493 has been updated per this conversation."}}