{"action":"created","comment":{"url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/comments/169285082","pull_request_review_id":97784011,"id":169285082,"diff_hunk":"@@ -146,6 +148,17 @@ public function prepare_template( $fields, $content, $shortcode_tag ) : string {\n \t\t\t\t$args['tag_id'] = $tag_id;\n \t\t\t}\n \n+\t\t\t// For post, display related article based on current post tags.\n+\t\t\tif ( 'post' === get_post_type() ) {\n+\t\t\t\tif ( $post_tags ) {\n+\t\t\t\t\t$tag_id_array = [];\n+\t\t\t\t\tforeach ( $post_tags as $tag ) {\n+\t\t\t\t\t\t$tag_id_array[] = $tag->term_id;\n+\t\t\t\t\t}\n+\t\t\t\t\t$args['tag_id'] = implode( ',', $tag_id_array );","path":"classes/controller/blocks/class-articles-controller.php","position":null,"original_position":31,"commit_id":"b812406e9473b183de5e0b28bfe6975dec434449","original_commit_id":"87f5dd26780c066020adfd1a2e3ceace60fc9d10","user":{"login":"sagarsdeshmukh","id":5357471,"avatar_url":"https://avatars3.githubusercontent.com/u/5357471?v=4","gravatar_id":"","url":"https://api.github.com/users/sagarsdeshmukh","html_url":"https://github.com/sagarsdeshmukh","followers_url":"https://api.github.com/users/sagarsdeshmukh/followers","following_url":"https://api.github.com/users/sagarsdeshmukh/following{/other_user}","gists_url":"https://api.github.com/users/sagarsdeshmukh/gists{/gist_id}","starred_url":"https://api.github.com/users/sagarsdeshmukh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sagarsdeshmukh/subscriptions","organizations_url":"https://api.github.com/users/sagarsdeshmukh/orgs","repos_url":"https://api.github.com/users/sagarsdeshmukh/repos","events_url":"https://api.github.com/users/sagarsdeshmukh/events{/privacy}","received_events_url":"https://api.github.com/users/sagarsdeshmukh/received_events","type":"User","site_admin":false},"body":"It is fixed. Please check.","created_at":"2018-02-20T11:05:05Z","updated_at":"2018-02-20T11:05:05Z","html_url":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219#discussion_r169285082","pull_request_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/comments/169285082"},"html":{"href":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219#discussion_r169285082"},"pull_request":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219"}},"in_reply_to_id":169240952},"pull_request":{"url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219","id":169626648,"html_url":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219","diff_url":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219.diff","patch_url":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219.patch","issue_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/219","number":219,"state":"open","locked":false,"title":"PLANET-1768 Post - display articles related to current post tags","user":{"login":"sagarsdeshmukh","id":5357471,"avatar_url":"https://avatars3.githubusercontent.com/u/5357471?v=4","gravatar_id":"","url":"https://api.github.com/users/sagarsdeshmukh","html_url":"https://github.com/sagarsdeshmukh","followers_url":"https://api.github.com/users/sagarsdeshmukh/followers","following_url":"https://api.github.com/users/sagarsdeshmukh/following{/other_user}","gists_url":"https://api.github.com/users/sagarsdeshmukh/gists{/gist_id}","starred_url":"https://api.github.com/users/sagarsdeshmukh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sagarsdeshmukh/subscriptions","organizations_url":"https://api.github.com/users/sagarsdeshmukh/orgs","repos_url":"https://api.github.com/users/sagarsdeshmukh/repos","events_url":"https://api.github.com/users/sagarsdeshmukh/events{/privacy}","received_events_url":"https://api.github.com/users/sagarsdeshmukh/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-02-16T13:41:01Z","updated_at":"2018-02-20T11:05:05Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8887d16994d819709a1fbb30cae3d773820adde4","assignee":null,"assignees":[],"requested_reviewers":[{"login":"koyan","id":2528229,"avatar_url":"https://avatars2.githubusercontent.com/u/2528229?v=4","gravatar_id":"","url":"https://api.github.com/users/koyan","html_url":"https://github.com/koyan","followers_url":"https://api.github.com/users/koyan/followers","following_url":"https://api.github.com/users/koyan/following{/other_user}","gists_url":"https://api.github.com/users/koyan/gists{/gist_id}","starred_url":"https://api.github.com/users/koyan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/koyan/subscriptions","organizations_url":"https://api.github.com/users/koyan/orgs","repos_url":"https://api.github.com/users/koyan/repos","events_url":"https://api.github.com/users/koyan/events{/privacy}","received_events_url":"https://api.github.com/users/koyan/received_events","type":"User","site_admin":false},{"login":"angtheod","id":14092452,"avatar_url":"https://avatars3.githubusercontent.com/u/14092452?v=4","gravatar_id":"","url":"https://api.github.com/users/angtheod","html_url":"https://github.com/angtheod","followers_url":"https://api.github.com/users/angtheod/followers","following_url":"https://api.github.com/users/angtheod/following{/other_user}","gists_url":"https://api.github.com/users/angtheod/gists{/gist_id}","starred_url":"https://api.github.com/users/angtheod/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angtheod/subscriptions","organizations_url":"https://api.github.com/users/angtheod/orgs","repos_url":"https://api.github.com/users/angtheod/repos","events_url":"https://api.github.com/users/angtheod/events{/privacy}","received_events_url":"https://api.github.com/users/angtheod/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":710303507,"url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/labels/review%20&%20merge","name":"review & merge","color":"fbca04","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219/commits","review_comments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219/comments","review_comment_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/comments{/number}","comments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/219/comments","statuses_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/statuses/b812406e9473b183de5e0b28bfe6975dec434449","head":{"label":"greenpeace:feature/1768-posts-related-articles-block","ref":"feature/1768-posts-related-articles-block","sha":"b812406e9473b183de5e0b28bfe6975dec434449","user":{"login":"greenpeace","id":727698,"avatar_url":"https://avatars2.githubusercontent.com/u/727698?v=4","gravatar_id":"","url":"https://api.github.com/users/greenpeace","html_url":"https://github.com/greenpeace","followers_url":"https://api.github.com/users/greenpeace/followers","following_url":"https://api.github.com/users/greenpeace/following{/other_user}","gists_url":"https://api.github.com/users/greenpeace/gists{/gist_id}","starred_url":"https://api.github.com/users/greenpeace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/greenpeace/subscriptions","organizations_url":"https://api.github.com/users/greenpeace/orgs","repos_url":"https://api.github.com/users/greenpeace/repos","events_url":"https://api.github.com/users/greenpeace/events{/privacy}","received_events_url":"https://api.github.com/users/greenpeace/received_events","type":"Organization","site_admin":false},"repo":{"id":104345695,"name":"planet4-plugin-blocks","full_name":"greenpeace/planet4-plugin-blocks","owner":{"login":"greenpeace","id":727698,"avatar_url":"https://avatars2.githubusercontent.com/u/727698?v=4","gravatar_id":"","url":"https://api.github.com/users/greenpeace","html_url":"https://github.com/greenpeace","followers_url":"https://api.github.com/users/greenpeace/followers","following_url":"https://api.github.com/users/greenpeace/following{/other_user}","gists_url":"https://api.github.com/users/greenpeace/gists{/gist_id}","starred_url":"https://api.github.com/users/greenpeace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/greenpeace/subscriptions","organizations_url":"https://api.github.com/users/greenpeace/orgs","repos_url":"https://api.github.com/users/greenpeace/repos","events_url":"https://api.github.com/users/greenpeace/events{/privacy}","received_events_url":"https://api.github.com/users/greenpeace/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/greenpeace/planet4-plugin-blocks","description":"This repository contains a WordPress plugin that creates all the blocks that will be available for usage by Shortcake UI.","fork":false,"url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks","forks_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/forks","keys_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/keys{/key_id}","collaborators_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/teams","hooks_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/hooks","issue_events_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/events{/number}","events_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/events","assignees_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/assignees{/user}","branches_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/branches{/branch}","tags_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/tags","blobs_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/refs{/sha}","trees_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/trees{/sha}","statuses_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/statuses/{sha}","languages_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/languages","stargazers_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/stargazers","contributors_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/contributors","subscribers_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/subscribers","subscription_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/subscription","commits_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/commits{/sha}","git_commits_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/commits{/sha}","comments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/comments{/number}","issue_comment_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/comments{/number}","contents_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/contents/{+path}","compare_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/compare/{base}...{head}","merges_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/merges","archive_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/downloads","issues_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues{/number}","pulls_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls{/number}","milestones_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/milestones{/number}","notifications_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/labels{/name}","releases_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/releases{/id}","deployments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/deployments","created_at":"2017-09-21T12:33:08Z","updated_at":"2017-12-15T08:10:15Z","pushed_at":"2018-02-20T11:03:02Z","git_url":"git://github.com/greenpeace/planet4-plugin-blocks.git","ssh_url":"git@github.com:greenpeace/planet4-plugin-blocks.git","clone_url":"https://github.com/greenpeace/planet4-plugin-blocks.git","svn_url":"https://github.com/greenpeace/planet4-plugin-blocks","homepage":null,"size":938,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":1,"open_issues":2,"watchers":1,"default_branch":"master"}},"base":{"label":"greenpeace:develop","ref":"develop","sha":"6cee37c98f410fdefb698bed5e70699b5e76f0d4","user":{"login":"greenpeace","id":727698,"avatar_url":"https://avatars2.githubusercontent.com/u/727698?v=4","gravatar_id":"","url":"https://api.github.com/users/greenpeace","html_url":"https://github.com/greenpeace","followers_url":"https://api.github.com/users/greenpeace/followers","following_url":"https://api.github.com/users/greenpeace/following{/other_user}","gists_url":"https://api.github.com/users/greenpeace/gists{/gist_id}","starred_url":"https://api.github.com/users/greenpeace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/greenpeace/subscriptions","organizations_url":"https://api.github.com/users/greenpeace/orgs","repos_url":"https://api.github.com/users/greenpeace/repos","events_url":"https://api.github.com/users/greenpeace/events{/privacy}","received_events_url":"https://api.github.com/users/greenpeace/received_events","type":"Organization","site_admin":false},"repo":{"id":104345695,"name":"planet4-plugin-blocks","full_name":"greenpeace/planet4-plugin-blocks","owner":{"login":"greenpeace","id":727698,"avatar_url":"https://avatars2.githubusercontent.com/u/727698?v=4","gravatar_id":"","url":"https://api.github.com/users/greenpeace","html_url":"https://github.com/greenpeace","followers_url":"https://api.github.com/users/greenpeace/followers","following_url":"https://api.github.com/users/greenpeace/following{/other_user}","gists_url":"https://api.github.com/users/greenpeace/gists{/gist_id}","starred_url":"https://api.github.com/users/greenpeace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/greenpeace/subscriptions","organizations_url":"https://api.github.com/users/greenpeace/orgs","repos_url":"https://api.github.com/users/greenpeace/repos","events_url":"https://api.github.com/users/greenpeace/events{/privacy}","received_events_url":"https://api.github.com/users/greenpeace/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/greenpeace/planet4-plugin-blocks","description":"This repository contains a WordPress plugin that creates all the blocks that will be available for usage by Shortcake UI.","fork":false,"url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks","forks_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/forks","keys_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/keys{/key_id}","collaborators_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/teams","hooks_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/hooks","issue_events_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/events{/number}","events_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/events","assignees_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/assignees{/user}","branches_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/branches{/branch}","tags_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/tags","blobs_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/refs{/sha}","trees_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/trees{/sha}","statuses_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/statuses/{sha}","languages_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/languages","stargazers_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/stargazers","contributors_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/contributors","subscribers_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/subscribers","subscription_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/subscription","commits_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/commits{/sha}","git_commits_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/git/commits{/sha}","comments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/comments{/number}","issue_comment_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/comments{/number}","contents_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/contents/{+path}","compare_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/compare/{base}...{head}","merges_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/merges","archive_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/downloads","issues_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues{/number}","pulls_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls{/number}","milestones_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/milestones{/number}","notifications_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/labels{/name}","releases_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/releases{/id}","deployments_url":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/deployments","created_at":"2017-09-21T12:33:08Z","updated_at":"2017-12-15T08:10:15Z","pushed_at":"2018-02-20T11:03:02Z","git_url":"git://github.com/greenpeace/planet4-plugin-blocks.git","ssh_url":"git@github.com:greenpeace/planet4-plugin-blocks.git","clone_url":"https://github.com/greenpeace/planet4-plugin-blocks.git","svn_url":"https://github.com/greenpeace/planet4-plugin-blocks","homepage":null,"size":938,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":1,"open_issues":2,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219"},"html":{"href":"https://github.com/greenpeace/planet4-plugin-blocks/pull/219"},"issue":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/219"},"comments":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/issues/219/comments"},"review_comments":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219/comments"},"review_comment":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/pulls/219/commits"},"statuses":{"href":"https://api.github.com/repos/greenpeace/planet4-plugin-blocks/statuses/b812406e9473b183de5e0b28bfe6975dec434449"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"sagarsdeshmukh"}}