{"action":"created","comment":{"url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/comments/191401283","pull_request_review_id":123964488,"id":191401283,"diff_hunk":"@@ -1675,6 +1676,7 @@ protected function is_multiple_terms_query() {\n \t * @param int    $status   Status code to use.\n \t */\n \tpublic function redirect( $location, $status = 302 ) {\n+\t\theader( 'X-Redirect-By: Yoast SEO' );","path":"frontend/class-frontend.php","position":12,"original_position":12,"commit_id":"8c5c3ec5693ebc8d649acf900d4def84ef8efa28","original_commit_id":"8c5c3ec5693ebc8d649acf900d4def84ef8efa28","user":{"login":"andizer","id":325040,"avatar_url":"https://avatars0.githubusercontent.com/u/325040?v=4","gravatar_id":"","url":"https://api.github.com/users/andizer","html_url":"https://github.com/andizer","followers_url":"https://api.github.com/users/andizer/followers","following_url":"https://api.github.com/users/andizer/following{/other_user}","gists_url":"https://api.github.com/users/andizer/gists{/gist_id}","starred_url":"https://api.github.com/users/andizer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andizer/subscriptions","organizations_url":"https://api.github.com/users/andizer/orgs","repos_url":"https://api.github.com/users/andizer/repos","events_url":"https://api.github.com/users/andizer/events{/privacy}","received_events_url":"https://api.github.com/users/andizer/received_events","type":"User","site_admin":false},"body":"We should be aware that WordPress 5.0.0 introduces a third argument for setting the x-redirect-by header. I don't know what will happen when two arguments are set twice. But I guess this header will be overwritten.\r\n\r\nhttps://core.trac.wordpress.org/browser/trunk/src/wp-includes/pluggable.php#L1341","created_at":"2018-05-29T12:17:57Z","updated_at":"2018-05-29T12:19:36Z","html_url":"https://github.com/Yoast/wordpress-seo/pull/9887#discussion_r191401283","pull_request_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/comments/191401283"},"html":{"href":"https://github.com/Yoast/wordpress-seo/pull/9887#discussion_r191401283"},"pull_request":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887"}}},"pull_request":{"url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887","id":191118941,"html_url":"https://github.com/Yoast/wordpress-seo/pull/9887","diff_url":"https://github.com/Yoast/wordpress-seo/pull/9887.diff","patch_url":"https://github.com/Yoast/wordpress-seo/pull/9887.patch","issue_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/9887","number":9887,"state":"open","locked":false,"title":"Add X-Redirect-By header to all redirects","user":{"login":"atimmer","id":584693,"avatar_url":"https://avatars3.githubusercontent.com/u/584693?v=4","gravatar_id":"","url":"https://api.github.com/users/atimmer","html_url":"https://github.com/atimmer","followers_url":"https://api.github.com/users/atimmer/followers","following_url":"https://api.github.com/users/atimmer/following{/other_user}","gists_url":"https://api.github.com/users/atimmer/gists{/gist_id}","starred_url":"https://api.github.com/users/atimmer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/atimmer/subscriptions","organizations_url":"https://api.github.com/users/atimmer/orgs","repos_url":"https://api.github.com/users/atimmer/repos","events_url":"https://api.github.com/users/atimmer/events{/privacy}","received_events_url":"https://api.github.com/users/atimmer/received_events","type":"User","site_admin":false},"body":"## Summary\n\nThis PR can be summarized in the following changelog entry:\n\n* Adds X-Redirect-By header to all redirects. Making the origin of redirects much easier to debug.\n\n## Relevant technical choices:\n\n* Because redirects are not abstracted I just added the `header` call before every redirect.\n\n## Test instructions\n\nThis PR can be tested by following these steps:\n\n* Test a redirect using a tool such as `curl -I` and see the X-Redirect-By header\n\n## Quality assurance\n\n* [ ] I have tested this code to the best of my abilities\n* [ ] I have added unittests to verify the code works as intended","created_at":"2018-05-29T11:46:44Z","updated_at":"2018-05-29T12:19:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2a1222242d7108acf578a018ee39ac04628ba813","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":267594565,"url":"https://api.github.com/repos/Yoast/wordpress-seo/labels/needs-code-review","name":"needs-code-review","color":"78BDF2","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887/commits","review_comments_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887/comments","review_comment_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/9887/comments","statuses_url":"https://api.github.com/repos/Yoast/wordpress-seo/statuses/8c5c3ec5693ebc8d649acf900d4def84ef8efa28","head":{"label":"Yoast:stories/add-x-redirect-by","ref":"stories/add-x-redirect-by","sha":"8c5c3ec5693ebc8d649acf900d4def84ef8efa28","user":{"login":"Yoast","id":4690436,"avatar_url":"https://avatars0.githubusercontent.com/u/4690436?v=4","gravatar_id":"","url":"https://api.github.com/users/Yoast","html_url":"https://github.com/Yoast","followers_url":"https://api.github.com/users/Yoast/followers","following_url":"https://api.github.com/users/Yoast/following{/other_user}","gists_url":"https://api.github.com/users/Yoast/gists{/gist_id}","starred_url":"https://api.github.com/users/Yoast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yoast/subscriptions","organizations_url":"https://api.github.com/users/Yoast/orgs","repos_url":"https://api.github.com/users/Yoast/repos","events_url":"https://api.github.com/users/Yoast/events{/privacy}","received_events_url":"https://api.github.com/users/Yoast/received_events","type":"Organization","site_admin":false},"repo":{"id":6723399,"name":"wordpress-seo","full_name":"Yoast/wordpress-seo","owner":{"login":"Yoast","id":4690436,"avatar_url":"https://avatars0.githubusercontent.com/u/4690436?v=4","gravatar_id":"","url":"https://api.github.com/users/Yoast","html_url":"https://github.com/Yoast","followers_url":"https://api.github.com/users/Yoast/followers","following_url":"https://api.github.com/users/Yoast/following{/other_user}","gists_url":"https://api.github.com/users/Yoast/gists{/gist_id}","starred_url":"https://api.github.com/users/Yoast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yoast/subscriptions","organizations_url":"https://api.github.com/users/Yoast/orgs","repos_url":"https://api.github.com/users/Yoast/repos","events_url":"https://api.github.com/users/Yoast/events{/privacy}","received_events_url":"https://api.github.com/users/Yoast/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Yoast/wordpress-seo","description":"Yoast SEO for WordPress","fork":false,"url":"https://api.github.com/repos/Yoast/wordpress-seo","forks_url":"https://api.github.com/repos/Yoast/wordpress-seo/forks","keys_url":"https://api.github.com/repos/Yoast/wordpress-seo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Yoast/wordpress-seo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Yoast/wordpress-seo/teams","hooks_url":"https://api.github.com/repos/Yoast/wordpress-seo/hooks","issue_events_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/events{/number}","events_url":"https://api.github.com/repos/Yoast/wordpress-seo/events","assignees_url":"https://api.github.com/repos/Yoast/wordpress-seo/assignees{/user}","branches_url":"https://api.github.com/repos/Yoast/wordpress-seo/branches{/branch}","tags_url":"https://api.github.com/repos/Yoast/wordpress-seo/tags","blobs_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/refs{/sha}","trees_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Yoast/wordpress-seo/statuses/{sha}","languages_url":"https://api.github.com/repos/Yoast/wordpress-seo/languages","stargazers_url":"https://api.github.com/repos/Yoast/wordpress-seo/stargazers","contributors_url":"https://api.github.com/repos/Yoast/wordpress-seo/contributors","subscribers_url":"https://api.github.com/repos/Yoast/wordpress-seo/subscribers","subscription_url":"https://api.github.com/repos/Yoast/wordpress-seo/subscription","commits_url":"https://api.github.com/repos/Yoast/wordpress-seo/commits{/sha}","git_commits_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/commits{/sha}","comments_url":"https://api.github.com/repos/Yoast/wordpress-seo/comments{/number}","issue_comment_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/comments{/number}","contents_url":"https://api.github.com/repos/Yoast/wordpress-seo/contents/{+path}","compare_url":"https://api.github.com/repos/Yoast/wordpress-seo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Yoast/wordpress-seo/merges","archive_url":"https://api.github.com/repos/Yoast/wordpress-seo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Yoast/wordpress-seo/downloads","issues_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues{/number}","pulls_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls{/number}","milestones_url":"https://api.github.com/repos/Yoast/wordpress-seo/milestones{/number}","notifications_url":"https://api.github.com/repos/Yoast/wordpress-seo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Yoast/wordpress-seo/labels{/name}","releases_url":"https://api.github.com/repos/Yoast/wordpress-seo/releases{/id}","deployments_url":"https://api.github.com/repos/Yoast/wordpress-seo/deployments","created_at":"2012-11-16T15:16:29Z","updated_at":"2018-05-29T11:38:37Z","pushed_at":"2018-05-29T12:00:24Z","git_url":"git://github.com/Yoast/wordpress-seo.git","ssh_url":"git@github.com:Yoast/wordpress-seo.git","clone_url":"https://github.com/Yoast/wordpress-seo.git","svn_url":"https://github.com/Yoast/wordpress-seo","homepage":"http://yoast.com/wordpress/seo/","size":259179,"stargazers_count":890,"watchers_count":890,"language":"PHP","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":525,"mirror_url":null,"archived":false,"open_issues_count":1046,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":525,"open_issues":1046,"watchers":890,"default_branch":"trunk"}},"base":{"label":"Yoast:trunk","ref":"trunk","sha":"7e4df8b03dbfc49e4d974c7b84d956376110517a","user":{"login":"Yoast","id":4690436,"avatar_url":"https://avatars0.githubusercontent.com/u/4690436?v=4","gravatar_id":"","url":"https://api.github.com/users/Yoast","html_url":"https://github.com/Yoast","followers_url":"https://api.github.com/users/Yoast/followers","following_url":"https://api.github.com/users/Yoast/following{/other_user}","gists_url":"https://api.github.com/users/Yoast/gists{/gist_id}","starred_url":"https://api.github.com/users/Yoast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yoast/subscriptions","organizations_url":"https://api.github.com/users/Yoast/orgs","repos_url":"https://api.github.com/users/Yoast/repos","events_url":"https://api.github.com/users/Yoast/events{/privacy}","received_events_url":"https://api.github.com/users/Yoast/received_events","type":"Organization","site_admin":false},"repo":{"id":6723399,"name":"wordpress-seo","full_name":"Yoast/wordpress-seo","owner":{"login":"Yoast","id":4690436,"avatar_url":"https://avatars0.githubusercontent.com/u/4690436?v=4","gravatar_id":"","url":"https://api.github.com/users/Yoast","html_url":"https://github.com/Yoast","followers_url":"https://api.github.com/users/Yoast/followers","following_url":"https://api.github.com/users/Yoast/following{/other_user}","gists_url":"https://api.github.com/users/Yoast/gists{/gist_id}","starred_url":"https://api.github.com/users/Yoast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yoast/subscriptions","organizations_url":"https://api.github.com/users/Yoast/orgs","repos_url":"https://api.github.com/users/Yoast/repos","events_url":"https://api.github.com/users/Yoast/events{/privacy}","received_events_url":"https://api.github.com/users/Yoast/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Yoast/wordpress-seo","description":"Yoast SEO for WordPress","fork":false,"url":"https://api.github.com/repos/Yoast/wordpress-seo","forks_url":"https://api.github.com/repos/Yoast/wordpress-seo/forks","keys_url":"https://api.github.com/repos/Yoast/wordpress-seo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Yoast/wordpress-seo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Yoast/wordpress-seo/teams","hooks_url":"https://api.github.com/repos/Yoast/wordpress-seo/hooks","issue_events_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/events{/number}","events_url":"https://api.github.com/repos/Yoast/wordpress-seo/events","assignees_url":"https://api.github.com/repos/Yoast/wordpress-seo/assignees{/user}","branches_url":"https://api.github.com/repos/Yoast/wordpress-seo/branches{/branch}","tags_url":"https://api.github.com/repos/Yoast/wordpress-seo/tags","blobs_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/refs{/sha}","trees_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Yoast/wordpress-seo/statuses/{sha}","languages_url":"https://api.github.com/repos/Yoast/wordpress-seo/languages","stargazers_url":"https://api.github.com/repos/Yoast/wordpress-seo/stargazers","contributors_url":"https://api.github.com/repos/Yoast/wordpress-seo/contributors","subscribers_url":"https://api.github.com/repos/Yoast/wordpress-seo/subscribers","subscription_url":"https://api.github.com/repos/Yoast/wordpress-seo/subscription","commits_url":"https://api.github.com/repos/Yoast/wordpress-seo/commits{/sha}","git_commits_url":"https://api.github.com/repos/Yoast/wordpress-seo/git/commits{/sha}","comments_url":"https://api.github.com/repos/Yoast/wordpress-seo/comments{/number}","issue_comment_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues/comments{/number}","contents_url":"https://api.github.com/repos/Yoast/wordpress-seo/contents/{+path}","compare_url":"https://api.github.com/repos/Yoast/wordpress-seo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Yoast/wordpress-seo/merges","archive_url":"https://api.github.com/repos/Yoast/wordpress-seo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Yoast/wordpress-seo/downloads","issues_url":"https://api.github.com/repos/Yoast/wordpress-seo/issues{/number}","pulls_url":"https://api.github.com/repos/Yoast/wordpress-seo/pulls{/number}","milestones_url":"https://api.github.com/repos/Yoast/wordpress-seo/milestones{/number}","notifications_url":"https://api.github.com/repos/Yoast/wordpress-seo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Yoast/wordpress-seo/labels{/name}","releases_url":"https://api.github.com/repos/Yoast/wordpress-seo/releases{/id}","deployments_url":"https://api.github.com/repos/Yoast/wordpress-seo/deployments","created_at":"2012-11-16T15:16:29Z","updated_at":"2018-05-29T11:38:37Z","pushed_at":"2018-05-29T12:00:24Z","git_url":"git://github.com/Yoast/wordpress-seo.git","ssh_url":"git@github.com:Yoast/wordpress-seo.git","clone_url":"https://github.com/Yoast/wordpress-seo.git","svn_url":"https://github.com/Yoast/wordpress-seo","homepage":"http://yoast.com/wordpress/seo/","size":259179,"stargazers_count":890,"watchers_count":890,"language":"PHP","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":525,"mirror_url":null,"archived":false,"open_issues_count":1046,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":525,"open_issues":1046,"watchers":890,"default_branch":"trunk"}},"_links":{"self":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887"},"html":{"href":"https://github.com/Yoast/wordpress-seo/pull/9887"},"issue":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/issues/9887"},"comments":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/issues/9887/comments"},"review_comments":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887/comments"},"review_comment":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/pulls/9887/commits"},"statuses":{"href":"https://api.github.com/repos/Yoast/wordpress-seo/statuses/8c5c3ec5693ebc8d649acf900d4def84ef8efa28"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"andizer"}}