{"action":"created","comment":{"url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments/78039439","id":78039439,"diff_hunk":"@@ -90,7 +90,12 @@ const handleResponse = (myFtContainerEl, flags, response) => {\n \tconst concepts = followed.concat(viewed, popularTopics)\n \t\t.filter(filterDuplicateConcepts)\n \t\t.filter(filterEmptyConcepts)\n-\t\t.slice(0, 4);\n+\t\t.slice(0, 4)\n+\t\t.map(concept => {\n+\t\t\t// add premium attribute to concept items\n+\t\t\tconst items = concept.items.map(item => Object.assign({}, item, { premium: /\\/cms\\/s\\/3\\//.test(item.webUrl)}));\n+\t\t\treturn Object.assign({}, concept, { items });\n+\t\t});","path":"client/components/myft/myft.js","position":10,"original_position":10,"commit_id":"8d795f12204a9b9574c22a6ba83025db29df7b70","original_commit_id":"8d795f12204a9b9574c22a6ba83025db29df7b70","user":{"login":"andygout","id":10484515,"avatar_url":"https://avatars.githubusercontent.com/u/10484515?v=3","gravatar_id":"","url":"https://api.github.com/users/andygout","html_url":"https://github.com/andygout","followers_url":"https://api.github.com/users/andygout/followers","following_url":"https://api.github.com/users/andygout/following{/other_user}","gists_url":"https://api.github.com/users/andygout/gists{/gist_id}","starred_url":"https://api.github.com/users/andygout/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andygout/subscriptions","organizations_url":"https://api.github.com/users/andygout/orgs","repos_url":"https://api.github.com/users/andygout/repos","events_url":"https://api.github.com/users/andygout/events{/privacy}","received_events_url":"https://api.github.com/users/andygout/received_events","type":"User","site_admin":false},"body":"Will endeavour to refactor the `reduce` function so not mutating the concepts and at same time will put it ahead of this mapping.","created_at":"2016-09-08T16:21:02Z","updated_at":"2016-09-08T16:21:02Z","html_url":"https://github.com/Financial-Times/next-front-page/pull/1029#discussion_r78039439","pull_request_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029","_links":{"self":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments/78039439"},"html":{"href":"https://github.com/Financial-Times/next-front-page/pull/1029#discussion_r78039439"},"pull_request":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029"}}},"pull_request":{"url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029","id":84488528,"html_url":"https://github.com/Financial-Times/next-front-page/pull/1029","diff_url":"https://github.com/Financial-Times/next-front-page/pull/1029.diff","patch_url":"https://github.com/Financial-Times/next-front-page/pull/1029.patch","issue_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/1029","number":1029,"state":"open","locked":false,"title":"Add: Premium labels to myFT cards","user":{"login":"andygout","id":10484515,"avatar_url":"https://avatars.githubusercontent.com/u/10484515?v=3","gravatar_id":"","url":"https://api.github.com/users/andygout","html_url":"https://github.com/andygout","followers_url":"https://api.github.com/users/andygout/followers","following_url":"https://api.github.com/users/andygout/following{/other_user}","gists_url":"https://api.github.com/users/andygout/gists{/gist_id}","starred_url":"https://api.github.com/users/andygout/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andygout/subscriptions","organizations_url":"https://api.github.com/users/andygout/orgs","repos_url":"https://api.github.com/users/andygout/repos","events_url":"https://api.github.com/users/andygout/events{/privacy}","received_events_url":"https://api.github.com/users/andygout/received_events","type":"User","site_admin":false},"body":"cc @andygnewman @bjfletcher \r\n\r\nGiven the myFT components are handled client-side, it seems the quickest fix to apply the `premium` attribute natively here in `next-front-page` (given that is all we need) rather than the work involved in getting `n-content-model` to also work client-side, especially given long term plan is have the premium status supplied directly and not require a transform.\r\n\r\n![screen shot 2016-09-08 at 15 21 00](https://cloud.githubusercontent.com/assets/10484515/18353179/fea5a278-75d8-11e6-99cb-2cfa77071b83.png)","created_at":"2016-09-08T14:29:56Z","updated_at":"2016-09-08T16:21:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fb9a03773b29b3492c9a50437d849b4db6a95925","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029/commits","review_comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029/comments","review_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/1029/comments","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/8d795f12204a9b9574c22a6ba83025db29df7b70","head":{"label":"Financial-Times:myft-cards-premium-labels","ref":"myft-cards-premium-labels","sha":"8d795f12204a9b9574c22a6ba83025db29df7b70","user":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"repo":{"id":37079565,"name":"next-front-page","full_name":"Financial-Times/next-front-page","owner":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Financial-Times/next-front-page","description":"Next FT front page","fork":false,"url":"https://api.github.com/repos/Financial-Times/next-front-page","forks_url":"https://api.github.com/repos/Financial-Times/next-front-page/forks","keys_url":"https://api.github.com/repos/Financial-Times/next-front-page/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Financial-Times/next-front-page/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Financial-Times/next-front-page/teams","hooks_url":"https://api.github.com/repos/Financial-Times/next-front-page/hooks","issue_events_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/events{/number}","events_url":"https://api.github.com/repos/Financial-Times/next-front-page/events","assignees_url":"https://api.github.com/repos/Financial-Times/next-front-page/assignees{/user}","branches_url":"https://api.github.com/repos/Financial-Times/next-front-page/branches{/branch}","tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/tags","blobs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/refs{/sha}","trees_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/{sha}","languages_url":"https://api.github.com/repos/Financial-Times/next-front-page/languages","stargazers_url":"https://api.github.com/repos/Financial-Times/next-front-page/stargazers","contributors_url":"https://api.github.com/repos/Financial-Times/next-front-page/contributors","subscribers_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscribers","subscription_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscription","commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/commits{/sha}","git_commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/commits{/sha}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/comments{/number}","issue_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/comments{/number}","contents_url":"https://api.github.com/repos/Financial-Times/next-front-page/contents/{+path}","compare_url":"https://api.github.com/repos/Financial-Times/next-front-page/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Financial-Times/next-front-page/merges","archive_url":"https://api.github.com/repos/Financial-Times/next-front-page/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Financial-Times/next-front-page/downloads","issues_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues{/number}","pulls_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls{/number}","milestones_url":"https://api.github.com/repos/Financial-Times/next-front-page/milestones{/number}","notifications_url":"https://api.github.com/repos/Financial-Times/next-front-page/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Financial-Times/next-front-page/labels{/name}","releases_url":"https://api.github.com/repos/Financial-Times/next-front-page/releases{/id}","deployments_url":"https://api.github.com/repos/Financial-Times/next-front-page/deployments","created_at":"2015-06-08T16:43:12Z","updated_at":"2016-08-19T15:32:20Z","pushed_at":"2016-09-08T16:19:00Z","git_url":"git://github.com/Financial-Times/next-front-page.git","ssh_url":"git@github.com:Financial-Times/next-front-page.git","clone_url":"https://github.com/Financial-Times/next-front-page.git","svn_url":"https://github.com/Financial-Times/next-front-page","homepage":"","size":2257,"stargazers_count":41,"watchers_count":41,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":14,"forks":6,"open_issues":14,"watchers":41,"default_branch":"master"}},"base":{"label":"Financial-Times:master","ref":"master","sha":"5c4a42ee7d33615f2844723910a51a40a462990f","user":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"repo":{"id":37079565,"name":"next-front-page","full_name":"Financial-Times/next-front-page","owner":{"login":"Financial-Times","id":3502508,"avatar_url":"https://avatars.githubusercontent.com/u/3502508?v=3","gravatar_id":"","url":"https://api.github.com/users/Financial-Times","html_url":"https://github.com/Financial-Times","followers_url":"https://api.github.com/users/Financial-Times/followers","following_url":"https://api.github.com/users/Financial-Times/following{/other_user}","gists_url":"https://api.github.com/users/Financial-Times/gists{/gist_id}","starred_url":"https://api.github.com/users/Financial-Times/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Financial-Times/subscriptions","organizations_url":"https://api.github.com/users/Financial-Times/orgs","repos_url":"https://api.github.com/users/Financial-Times/repos","events_url":"https://api.github.com/users/Financial-Times/events{/privacy}","received_events_url":"https://api.github.com/users/Financial-Times/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Financial-Times/next-front-page","description":"Next FT front page","fork":false,"url":"https://api.github.com/repos/Financial-Times/next-front-page","forks_url":"https://api.github.com/repos/Financial-Times/next-front-page/forks","keys_url":"https://api.github.com/repos/Financial-Times/next-front-page/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Financial-Times/next-front-page/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Financial-Times/next-front-page/teams","hooks_url":"https://api.github.com/repos/Financial-Times/next-front-page/hooks","issue_events_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/events{/number}","events_url":"https://api.github.com/repos/Financial-Times/next-front-page/events","assignees_url":"https://api.github.com/repos/Financial-Times/next-front-page/assignees{/user}","branches_url":"https://api.github.com/repos/Financial-Times/next-front-page/branches{/branch}","tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/tags","blobs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/refs{/sha}","trees_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/{sha}","languages_url":"https://api.github.com/repos/Financial-Times/next-front-page/languages","stargazers_url":"https://api.github.com/repos/Financial-Times/next-front-page/stargazers","contributors_url":"https://api.github.com/repos/Financial-Times/next-front-page/contributors","subscribers_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscribers","subscription_url":"https://api.github.com/repos/Financial-Times/next-front-page/subscription","commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/commits{/sha}","git_commits_url":"https://api.github.com/repos/Financial-Times/next-front-page/git/commits{/sha}","comments_url":"https://api.github.com/repos/Financial-Times/next-front-page/comments{/number}","issue_comment_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues/comments{/number}","contents_url":"https://api.github.com/repos/Financial-Times/next-front-page/contents/{+path}","compare_url":"https://api.github.com/repos/Financial-Times/next-front-page/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Financial-Times/next-front-page/merges","archive_url":"https://api.github.com/repos/Financial-Times/next-front-page/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Financial-Times/next-front-page/downloads","issues_url":"https://api.github.com/repos/Financial-Times/next-front-page/issues{/number}","pulls_url":"https://api.github.com/repos/Financial-Times/next-front-page/pulls{/number}","milestones_url":"https://api.github.com/repos/Financial-Times/next-front-page/milestones{/number}","notifications_url":"https://api.github.com/repos/Financial-Times/next-front-page/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Financial-Times/next-front-page/labels{/name}","releases_url":"https://api.github.com/repos/Financial-Times/next-front-page/releases{/id}","deployments_url":"https://api.github.com/repos/Financial-Times/next-front-page/deployments","created_at":"2015-06-08T16:43:12Z","updated_at":"2016-08-19T15:32:20Z","pushed_at":"2016-09-08T16:19:00Z","git_url":"git://github.com/Financial-Times/next-front-page.git","ssh_url":"git@github.com:Financial-Times/next-front-page.git","clone_url":"https://github.com/Financial-Times/next-front-page.git","svn_url":"https://github.com/Financial-Times/next-front-page","homepage":"","size":2257,"stargazers_count":41,"watchers_count":41,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":14,"forks":6,"open_issues":14,"watchers":41,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029"},"html":{"href":"https://github.com/Financial-Times/next-front-page/pull/1029"},"issue":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/issues/1029"},"comments":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/issues/1029/comments"},"review_comments":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029/comments"},"review_comment":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/pulls/1029/commits"},"statuses":{"href":"https://api.github.com/repos/Financial-Times/next-front-page/statuses/8d795f12204a9b9574c22a6ba83025db29df7b70"}}}}
{"actor":{"display_login":"andygout"}}