{"action":"created","comment":{"url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/comments/220590966","pull_request_review_id":159032344,"id":220590966,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMDU5MDk2Ng==","diff_hunk":"@@ -4,24 +4,34 @@\n namespace App\\Controller\\Articles;\n \n use App\\Controller\\BaseController;\n-use App\\ExternalApi\\Isite\\Service\\IsiteService;\n+use App\\Ds2013\\Presenters\\Utilities\\Paginator\\PaginatorPresenter;\n+use App\\ExternalApi\\Isite\\Service\\ArticleService;\n use BBC\\ProgrammesPagesService\\Domain\\Entity\\CoreEntity;\n use BBC\\ProgrammesPagesService\\Domain\\Entity\\Programme;\n \n class IndexController extends BaseController\n {\n-    public function __invoke(CoreEntity $coreEntity, IsiteService $isiteService)\n+    public function __invoke(CoreEntity $coreEntity, ArticleService $isiteService)\n     {\n         $this->setContextAndPreloadBranding($coreEntity);\n \n         $articles = [];\n         $parameters = ['coreEntity' => $coreEntity, 'articles' => $articles, 'paginatorPresenter' => null];\n         if ($coreEntity instanceof Programme) {\n             $parameters['programme'] = $coreEntity; //so the the base 2013 template sets the footer\n+\n+            $articlesResult = $isiteService->getArticlesByProgramme($coreEntity, $this->getPage())->wait();\n+            $articles = $articlesResult->getDomainModels();\n+\n+            if ($articlesResult->getTotal() > 48) {\n+                $parameters['paginatorPresenter'] = new PaginatorPresenter($this->getPage(), 48, $articlesResult->getTotal());\n+            }\n         }\n \n         if (empty($articles)) {\n             $this->response()->setStatusCode(404);\n+        } else {\n+            $parameters['articles'] = $articles;","path":"src/Controller/Articles/IndexController.php","position":33,"original_position":33,"commit_id":"c39da634cbdacacc5c6f71e3a43a42aec23325ad","original_commit_id":"c39da634cbdacacc5c6f71e3a43a42aec23325ad","user":{"login":"votemike","id":3957065,"node_id":"MDQ6VXNlcjM5NTcwNjU=","avatar_url":"https://avatars3.githubusercontent.com/u/3957065?v=4","gravatar_id":"","url":"https://api.github.com/users/votemike","html_url":"https://github.com/votemike","followers_url":"https://api.github.com/users/votemike/followers","following_url":"https://api.github.com/users/votemike/following{/other_user}","gists_url":"https://api.github.com/users/votemike/gists{/gist_id}","starred_url":"https://api.github.com/users/votemike/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/votemike/subscriptions","organizations_url":"https://api.github.com/users/votemike/orgs","repos_url":"https://api.github.com/users/votemike/repos","events_url":"https://api.github.com/users/votemike/events{/privacy}","received_events_url":"https://api.github.com/users/votemike/received_events","type":"User","site_admin":false},"body":"I'm not sure what you mean.","created_at":"2018-09-26T14:38:20Z","updated_at":"2018-09-26T14:38:20Z","html_url":"https://github.com/bbc/programmes-frontend/pull/751#discussion_r220590966","pull_request_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/comments/220590966"},"html":{"href":"https://github.com/bbc/programmes-frontend/pull/751#discussion_r220590966"},"pull_request":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751"}},"in_reply_to_id":220569013},"pull_request":{"url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751","id":218317954,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE4MzE3OTU0","html_url":"https://github.com/bbc/programmes-frontend/pull/751","diff_url":"https://github.com/bbc/programmes-frontend/pull/751.diff","patch_url":"https://github.com/bbc/programmes-frontend/pull/751.patch","issue_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/751","number":751,"state":"open","locked":false,"title":"PROGRAMMES-6593 Article List Page","user":{"login":"votemike","id":3957065,"node_id":"MDQ6VXNlcjM5NTcwNjU=","avatar_url":"https://avatars3.githubusercontent.com/u/3957065?v=4","gravatar_id":"","url":"https://api.github.com/users/votemike","html_url":"https://github.com/votemike","followers_url":"https://api.github.com/users/votemike/followers","following_url":"https://api.github.com/users/votemike/following{/other_user}","gists_url":"https://api.github.com/users/votemike/gists{/gist_id}","starred_url":"https://api.github.com/users/votemike/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/votemike/subscriptions","organizations_url":"https://api.github.com/users/votemike/orgs","repos_url":"https://api.github.com/users/votemike/repos","events_url":"https://api.github.com/users/votemike/events{/privacy}","received_events_url":"https://api.github.com/users/votemike/received_events","type":"User","site_admin":false},"body":"https://jira.dev.bbc.co.uk/browse/PROGRAMMES-6593","created_at":"2018-09-26T13:32:28Z","updated_at":"2018-09-26T14:38:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"61fc544828a3169bf2c9d887f740f7912788986d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751/commits","review_comments_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751/comments","review_comment_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/751/comments","statuses_url":"https://api.github.com/repos/bbc/programmes-frontend/statuses/c39da634cbdacacc5c6f71e3a43a42aec23325ad","head":{"label":"bbc:PROGRAMMES-6593-article-list-page","ref":"PROGRAMMES-6593-article-list-page","sha":"c39da634cbdacacc5c6f71e3a43a42aec23325ad","user":{"login":"bbc","id":828722,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgyODcyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/828722?v=4","gravatar_id":"","url":"https://api.github.com/users/bbc","html_url":"https://github.com/bbc","followers_url":"https://api.github.com/users/bbc/followers","following_url":"https://api.github.com/users/bbc/following{/other_user}","gists_url":"https://api.github.com/users/bbc/gists{/gist_id}","starred_url":"https://api.github.com/users/bbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbc/subscriptions","organizations_url":"https://api.github.com/users/bbc/orgs","repos_url":"https://api.github.com/users/bbc/repos","events_url":"https://api.github.com/users/bbc/events{/privacy}","received_events_url":"https://api.github.com/users/bbc/received_events","type":"Organization","site_admin":false},"repo":{"id":85298889,"node_id":"MDEwOlJlcG9zaXRvcnk4NTI5ODg4OQ==","name":"programmes-frontend","full_name":"bbc/programmes-frontend","private":false,"owner":{"login":"bbc","id":828722,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgyODcyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/828722?v=4","gravatar_id":"","url":"https://api.github.com/users/bbc","html_url":"https://github.com/bbc","followers_url":"https://api.github.com/users/bbc/followers","following_url":"https://api.github.com/users/bbc/following{/other_user}","gists_url":"https://api.github.com/users/bbc/gists{/gist_id}","starred_url":"https://api.github.com/users/bbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbc/subscriptions","organizations_url":"https://api.github.com/users/bbc/orgs","repos_url":"https://api.github.com/users/bbc/repos","events_url":"https://api.github.com/users/bbc/events{/privacy}","received_events_url":"https://api.github.com/users/bbc/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/bbc/programmes-frontend","description":"The new frontend for bbc.co.uk/programmes","fork":false,"url":"https://api.github.com/repos/bbc/programmes-frontend","forks_url":"https://api.github.com/repos/bbc/programmes-frontend/forks","keys_url":"https://api.github.com/repos/bbc/programmes-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bbc/programmes-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bbc/programmes-frontend/teams","hooks_url":"https://api.github.com/repos/bbc/programmes-frontend/hooks","issue_events_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/bbc/programmes-frontend/events","assignees_url":"https://api.github.com/repos/bbc/programmes-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/bbc/programmes-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/bbc/programmes-frontend/tags","blobs_url":"https://api.github.com/repos/bbc/programmes-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bbc/programmes-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bbc/programmes-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/bbc/programmes-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bbc/programmes-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/bbc/programmes-frontend/languages","stargazers_url":"https://api.github.com/repos/bbc/programmes-frontend/stargazers","contributors_url":"https://api.github.com/repos/bbc/programmes-frontend/contributors","subscribers_url":"https://api.github.com/repos/bbc/programmes-frontend/subscribers","subscription_url":"https://api.github.com/repos/bbc/programmes-frontend/subscription","commits_url":"https://api.github.com/repos/bbc/programmes-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/bbc/programmes-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/bbc/programmes-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/comments{/number}","contents_url":"https://api.github.com/repos/bbc/programmes-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/bbc/programmes-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bbc/programmes-frontend/merges","archive_url":"https://api.github.com/repos/bbc/programmes-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bbc/programmes-frontend/downloads","issues_url":"https://api.github.com/repos/bbc/programmes-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/bbc/programmes-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/bbc/programmes-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bbc/programmes-frontend/labels{/name}","releases_url":"https://api.github.com/repos/bbc/programmes-frontend/releases{/id}","deployments_url":"https://api.github.com/repos/bbc/programmes-frontend/deployments","created_at":"2017-03-17T10:19:20Z","updated_at":"2018-09-26T10:08:20Z","pushed_at":"2018-09-26T13:32:29Z","git_url":"git://github.com/bbc/programmes-frontend.git","ssh_url":"git@github.com:bbc/programmes-frontend.git","clone_url":"https://github.com/bbc/programmes-frontend.git","svn_url":"https://github.com/bbc/programmes-frontend","homepage":"","size":3966,"stargazers_count":18,"watchers_count":18,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"archived":false,"open_issues_count":8,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":4,"open_issues":8,"watchers":18,"default_branch":"develop"}},"base":{"label":"bbc:develop","ref":"develop","sha":"f6e0293b885e148135a02b9734bcbe80cc4572b7","user":{"login":"bbc","id":828722,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgyODcyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/828722?v=4","gravatar_id":"","url":"https://api.github.com/users/bbc","html_url":"https://github.com/bbc","followers_url":"https://api.github.com/users/bbc/followers","following_url":"https://api.github.com/users/bbc/following{/other_user}","gists_url":"https://api.github.com/users/bbc/gists{/gist_id}","starred_url":"https://api.github.com/users/bbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbc/subscriptions","organizations_url":"https://api.github.com/users/bbc/orgs","repos_url":"https://api.github.com/users/bbc/repos","events_url":"https://api.github.com/users/bbc/events{/privacy}","received_events_url":"https://api.github.com/users/bbc/received_events","type":"Organization","site_admin":false},"repo":{"id":85298889,"node_id":"MDEwOlJlcG9zaXRvcnk4NTI5ODg4OQ==","name":"programmes-frontend","full_name":"bbc/programmes-frontend","private":false,"owner":{"login":"bbc","id":828722,"node_id":"MDEyOk9yZ2FuaXphdGlvbjgyODcyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/828722?v=4","gravatar_id":"","url":"https://api.github.com/users/bbc","html_url":"https://github.com/bbc","followers_url":"https://api.github.com/users/bbc/followers","following_url":"https://api.github.com/users/bbc/following{/other_user}","gists_url":"https://api.github.com/users/bbc/gists{/gist_id}","starred_url":"https://api.github.com/users/bbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbc/subscriptions","organizations_url":"https://api.github.com/users/bbc/orgs","repos_url":"https://api.github.com/users/bbc/repos","events_url":"https://api.github.com/users/bbc/events{/privacy}","received_events_url":"https://api.github.com/users/bbc/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/bbc/programmes-frontend","description":"The new frontend for bbc.co.uk/programmes","fork":false,"url":"https://api.github.com/repos/bbc/programmes-frontend","forks_url":"https://api.github.com/repos/bbc/programmes-frontend/forks","keys_url":"https://api.github.com/repos/bbc/programmes-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bbc/programmes-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bbc/programmes-frontend/teams","hooks_url":"https://api.github.com/repos/bbc/programmes-frontend/hooks","issue_events_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/bbc/programmes-frontend/events","assignees_url":"https://api.github.com/repos/bbc/programmes-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/bbc/programmes-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/bbc/programmes-frontend/tags","blobs_url":"https://api.github.com/repos/bbc/programmes-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bbc/programmes-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bbc/programmes-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/bbc/programmes-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bbc/programmes-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/bbc/programmes-frontend/languages","stargazers_url":"https://api.github.com/repos/bbc/programmes-frontend/stargazers","contributors_url":"https://api.github.com/repos/bbc/programmes-frontend/contributors","subscribers_url":"https://api.github.com/repos/bbc/programmes-frontend/subscribers","subscription_url":"https://api.github.com/repos/bbc/programmes-frontend/subscription","commits_url":"https://api.github.com/repos/bbc/programmes-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/bbc/programmes-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/bbc/programmes-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/bbc/programmes-frontend/issues/comments{/number}","contents_url":"https://api.github.com/repos/bbc/programmes-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/bbc/programmes-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bbc/programmes-frontend/merges","archive_url":"https://api.github.com/repos/bbc/programmes-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bbc/programmes-frontend/downloads","issues_url":"https://api.github.com/repos/bbc/programmes-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/bbc/programmes-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/bbc/programmes-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/bbc/programmes-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bbc/programmes-frontend/labels{/name}","releases_url":"https://api.github.com/repos/bbc/programmes-frontend/releases{/id}","deployments_url":"https://api.github.com/repos/bbc/programmes-frontend/deployments","created_at":"2017-03-17T10:19:20Z","updated_at":"2018-09-26T10:08:20Z","pushed_at":"2018-09-26T13:32:29Z","git_url":"git://github.com/bbc/programmes-frontend.git","ssh_url":"git@github.com:bbc/programmes-frontend.git","clone_url":"https://github.com/bbc/programmes-frontend.git","svn_url":"https://github.com/bbc/programmes-frontend","homepage":"","size":3966,"stargazers_count":18,"watchers_count":18,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"archived":false,"open_issues_count":8,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":4,"open_issues":8,"watchers":18,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751"},"html":{"href":"https://github.com/bbc/programmes-frontend/pull/751"},"issue":{"href":"https://api.github.com/repos/bbc/programmes-frontend/issues/751"},"comments":{"href":"https://api.github.com/repos/bbc/programmes-frontend/issues/751/comments"},"review_comments":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751/comments"},"review_comment":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bbc/programmes-frontend/pulls/751/commits"},"statuses":{"href":"https://api.github.com/repos/bbc/programmes-frontend/statuses/c39da634cbdacacc5c6f71e3a43a42aec23325ad"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"votemike"}}