{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla/activity-stream/pulls/comments/208974563","pull_request_review_id":144896809,"id":208974563,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwODk3NDU2Mw==","diff_hunk":"@@ -48,9 +48,29 @@ export class _Base extends React.PureComponent {\n     this.updateTheme();\n   }\n \n-  componentWillUpdate({App}) {\n+  hasSectionChanged(nextProps) {\n+    const [nPropsSections] = nextProps.Sections;","path":"content-src/components/Base/Base.jsx","position":6,"original_position":6,"commit_id":"ce61c6a56a5f78d7a9bd0a0b74278e2bf2743b18","original_commit_id":"ce61c6a56a5f78d7a9bd0a0b74278e2bf2743b18","user":{"login":"k88hudson","id":1455535,"node_id":"MDQ6VXNlcjE0NTU1MzU=","avatar_url":"https://avatars3.githubusercontent.com/u/1455535?v=4","gravatar_id":"","url":"https://api.github.com/users/k88hudson","html_url":"https://github.com/k88hudson","followers_url":"https://api.github.com/users/k88hudson/followers","following_url":"https://api.github.com/users/k88hudson/following{/other_user}","gists_url":"https://api.github.com/users/k88hudson/gists{/gist_id}","starred_url":"https://api.github.com/users/k88hudson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k88hudson/subscriptions","organizations_url":"https://api.github.com/users/k88hudson/orgs","repos_url":"https://api.github.com/users/k88hudson/repos","events_url":"https://api.github.com/users/k88hudson/events{/privacy}","received_events_url":"https://api.github.com/users/k88hudson/received_events","type":"User","site_admin":false},"body":"Can you do perhaps do `nextProps.Sections.find(section => section.id === \"topstories\")` to make this more resilient to future changes?\r\n\r\nAdditionally, it might be a good idea to call this `hasTopStoriesSectionChanged`","created_at":"2018-08-09T15:27:41Z","updated_at":"2018-08-09T15:30:57Z","html_url":"https://github.com/mozilla/activity-stream/pull/4276#discussion_r208974563","pull_request_url":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/comments/208974563"},"html":{"href":"https://github.com/mozilla/activity-stream/pull/4276#discussion_r208974563"},"pull_request":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276"}}},"pull_request":{"url":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276","id":205299123,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA1Mjk5MTIz","html_url":"https://github.com/mozilla/activity-stream/pull/4276","diff_url":"https://github.com/mozilla/activity-stream/pull/4276.diff","patch_url":"https://github.com/mozilla/activity-stream/pull/4276.patch","issue_url":"https://api.github.com/repos/mozilla/activity-stream/issues/4276","number":4276,"state":"open","locked":false,"title":"Fix Bug 1479458 - Spocs updating when pref changes from a shield study","user":{"login":"ScottDowne","id":197334,"node_id":"MDQ6VXNlcjE5NzMzNA==","avatar_url":"https://avatars0.githubusercontent.com/u/197334?v=4","gravatar_id":"","url":"https://api.github.com/users/ScottDowne","html_url":"https://github.com/ScottDowne","followers_url":"https://api.github.com/users/ScottDowne/followers","following_url":"https://api.github.com/users/ScottDowne/following{/other_user}","gists_url":"https://api.github.com/users/ScottDowne/gists{/gist_id}","starred_url":"https://api.github.com/users/ScottDowne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ScottDowne/subscriptions","organizations_url":"https://api.github.com/users/ScottDowne/orgs","repos_url":"https://api.github.com/users/ScottDowne/repos","events_url":"https://api.github.com/users/ScottDowne/events{/privacy}","received_events_url":"https://api.github.com/users/ScottDowne/received_events","type":"User","site_admin":false},"body":"To test:\r\n\r\n1. Set the pref \"browser.newtabpage.activity-stream.feeds.section.topstories.options\" to default.\r\n\r\n2. load about:home take not of the third rec. This ensures that we have a preloaded tab generated with default recs. You can keep this tab open, or close it, both are viable and shouldn't matter.\r\n\r\n3. Update \"browser.newtabpage.activity-stream.feeds.section.topstories.options\" pref to:\r\n```\r\n{\"api_key_pref\":\"extensions.pocket.oAuthConsumerKey\",\"hidden\":false,\"provider_icon\":\"pocket\",\"provider_name\":\"Pocket\",\"read_more_endpoint\":\"https://getpocket.com/explore/trending?src=fx_new_tab\",\"stories_endpoint\":\"file:///home/scott/spoc.json\",\"stories_referrer\":\"https://getpocket.com/recommendations\",\"topics_endpoint\":\"https://getpocket.cdn.mozilla.net/v3/firefox/trending-topics?version=2&consumer_key=$apiKey&locale_lang=en-US\",\"show_spocs\":true,\"personalized\":true}\r\n```\r\n\r\nYou'll also need a file saved on your local system and to update the stories_endpoint with the file. i used this file: https://bug1479458.bmoattachments.org/attachment.cgi?id=8997024\r\n\r\n4. open about:home again (or another one).\r\n\r\n5. Ensure the new tab updates the third rec with something from theringer.com titled \"The Kawhi-DeRozan Trade Is a Win for Both the Spurs and Raptors\" If you kept the initial tab open from step 2, that should also be updated.\r\n\r\nThis basically simulates shield updating the pref.","created_at":"2018-08-01T03:28:07Z","updated_at":"2018-08-09T15:30:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d3549c97f12a33bca6f1aa78774b55c6a930eae0","assignee":{"login":"k88hudson","id":1455535,"node_id":"MDQ6VXNlcjE0NTU1MzU=","avatar_url":"https://avatars3.githubusercontent.com/u/1455535?v=4","gravatar_id":"","url":"https://api.github.com/users/k88hudson","html_url":"https://github.com/k88hudson","followers_url":"https://api.github.com/users/k88hudson/followers","following_url":"https://api.github.com/users/k88hudson/following{/other_user}","gists_url":"https://api.github.com/users/k88hudson/gists{/gist_id}","starred_url":"https://api.github.com/users/k88hudson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k88hudson/subscriptions","organizations_url":"https://api.github.com/users/k88hudson/orgs","repos_url":"https://api.github.com/users/k88hudson/repos","events_url":"https://api.github.com/users/k88hudson/events{/privacy}","received_events_url":"https://api.github.com/users/k88hudson/received_events","type":"User","site_admin":false},"assignees":[{"login":"k88hudson","id":1455535,"node_id":"MDQ6VXNlcjE0NTU1MzU=","avatar_url":"https://avatars3.githubusercontent.com/u/1455535?v=4","gravatar_id":"","url":"https://api.github.com/users/k88hudson","html_url":"https://github.com/k88hudson","followers_url":"https://api.github.com/users/k88hudson/followers","following_url":"https://api.github.com/users/k88hudson/following{/other_user}","gists_url":"https://api.github.com/users/k88hudson/gists{/gist_id}","starred_url":"https://api.github.com/users/k88hudson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k88hudson/subscriptions","organizations_url":"https://api.github.com/users/k88hudson/orgs","repos_url":"https://api.github.com/users/k88hudson/repos","events_url":"https://api.github.com/users/k88hudson/events{/privacy}","received_events_url":"https://api.github.com/users/k88hudson/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":334509354,"node_id":"MDU6TGFiZWwzMzQ1MDkzNTQ=","url":"https://api.github.com/repos/mozilla/activity-stream/labels/PR%20/%20Needs%20review","name":"PR / Needs review","color":"1d76db","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276/commits","review_comments_url":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276/comments","review_comment_url":"https://api.github.com/repos/mozilla/activity-stream/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla/activity-stream/issues/4276/comments","statuses_url":"https://api.github.com/repos/mozilla/activity-stream/statuses/ce61c6a56a5f78d7a9bd0a0b74278e2bf2743b18","head":{"label":"ScottDowne:t-1479458","ref":"t-1479458","sha":"ce61c6a56a5f78d7a9bd0a0b74278e2bf2743b18","user":{"login":"ScottDowne","id":197334,"node_id":"MDQ6VXNlcjE5NzMzNA==","avatar_url":"https://avatars0.githubusercontent.com/u/197334?v=4","gravatar_id":"","url":"https://api.github.com/users/ScottDowne","html_url":"https://github.com/ScottDowne","followers_url":"https://api.github.com/users/ScottDowne/followers","following_url":"https://api.github.com/users/ScottDowne/following{/other_user}","gists_url":"https://api.github.com/users/ScottDowne/gists{/gist_id}","starred_url":"https://api.github.com/users/ScottDowne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ScottDowne/subscriptions","organizations_url":"https://api.github.com/users/ScottDowne/orgs","repos_url":"https://api.github.com/users/ScottDowne/repos","events_url":"https://api.github.com/users/ScottDowne/events{/privacy}","received_events_url":"https://api.github.com/users/ScottDowne/received_events","type":"User","site_admin":false},"repo":{"id":139862949,"node_id":"MDEwOlJlcG9zaXRvcnkxMzk4NjI5NDk=","name":"activity-stream","full_name":"ScottDowne/activity-stream","owner":{"login":"ScottDowne","id":197334,"node_id":"MDQ6VXNlcjE5NzMzNA==","avatar_url":"https://avatars0.githubusercontent.com/u/197334?v=4","gravatar_id":"","url":"https://api.github.com/users/ScottDowne","html_url":"https://github.com/ScottDowne","followers_url":"https://api.github.com/users/ScottDowne/followers","following_url":"https://api.github.com/users/ScottDowne/following{/other_user}","gists_url":"https://api.github.com/users/ScottDowne/gists{/gist_id}","starred_url":"https://api.github.com/users/ScottDowne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ScottDowne/subscriptions","organizations_url":"https://api.github.com/users/ScottDowne/orgs","repos_url":"https://api.github.com/users/ScottDowne/repos","events_url":"https://api.github.com/users/ScottDowne/events{/privacy}","received_events_url":"https://api.github.com/users/ScottDowne/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ScottDowne/activity-stream","description":"A refreshed \"new tab page\" for Firefox","fork":true,"url":"https://api.github.com/repos/ScottDowne/activity-stream","forks_url":"https://api.github.com/repos/ScottDowne/activity-stream/forks","keys_url":"https://api.github.com/repos/ScottDowne/activity-stream/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ScottDowne/activity-stream/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ScottDowne/activity-stream/teams","hooks_url":"https://api.github.com/repos/ScottDowne/activity-stream/hooks","issue_events_url":"https://api.github.com/repos/ScottDowne/activity-stream/issues/events{/number}","events_url":"https://api.github.com/repos/ScottDowne/activity-stream/events","assignees_url":"https://api.github.com/repos/ScottDowne/activity-stream/assignees{/user}","branches_url":"https://api.github.com/repos/ScottDowne/activity-stream/branches{/branch}","tags_url":"https://api.github.com/repos/ScottDowne/activity-stream/tags","blobs_url":"https://api.github.com/repos/ScottDowne/activity-stream/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ScottDowne/activity-stream/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ScottDowne/activity-stream/git/refs{/sha}","trees_url":"https://api.github.com/repos/ScottDowne/activity-stream/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ScottDowne/activity-stream/statuses/{sha}","languages_url":"https://api.github.com/repos/ScottDowne/activity-stream/languages","stargazers_url":"https://api.github.com/repos/ScottDowne/activity-stream/stargazers","contributors_url":"https://api.github.com/repos/ScottDowne/activity-stream/contributors","subscribers_url":"https://api.github.com/repos/ScottDowne/activity-stream/subscribers","subscription_url":"https://api.github.com/repos/ScottDowne/activity-stream/subscription","commits_url":"https://api.github.com/repos/ScottDowne/activity-stream/commits{/sha}","git_commits_url":"https://api.github.com/repos/ScottDowne/activity-stream/git/commits{/sha}","comments_url":"https://api.github.com/repos/ScottDowne/activity-stream/comments{/number}","issue_comment_url":"https://api.github.com/repos/ScottDowne/activity-stream/issues/comments{/number}","contents_url":"https://api.github.com/repos/ScottDowne/activity-stream/contents/{+path}","compare_url":"https://api.github.com/repos/ScottDowne/activity-stream/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ScottDowne/activity-stream/merges","archive_url":"https://api.github.com/repos/ScottDowne/activity-stream/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ScottDowne/activity-stream/downloads","issues_url":"https://api.github.com/repos/ScottDowne/activity-stream/issues{/number}","pulls_url":"https://api.github.com/repos/ScottDowne/activity-stream/pulls{/number}","milestones_url":"https://api.github.com/repos/ScottDowne/activity-stream/milestones{/number}","notifications_url":"https://api.github.com/repos/ScottDowne/activity-stream/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ScottDowne/activity-stream/labels{/name}","releases_url":"https://api.github.com/repos/ScottDowne/activity-stream/releases{/id}","deployments_url":"https://api.github.com/repos/ScottDowne/activity-stream/deployments","created_at":"2018-07-05T14:43:36Z","updated_at":"2018-07-05T14:43:39Z","pushed_at":"2018-08-07T20:03:58Z","git_url":"git://github.com/ScottDowne/activity-stream.git","ssh_url":"git@github.com:ScottDowne/activity-stream.git","clone_url":"https://github.com/ScottDowne/activity-stream.git","svn_url":"https://github.com/ScottDowne/activity-stream","homepage":"","size":10674,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mpl-2.0","name":"Mozilla Public License 2.0","spdx_id":"MPL-2.0","url":"https://api.github.com/licenses/mpl-2.0","node_id":"MDc6TGljZW5zZTE0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mozilla:master","ref":"master","sha":"a75d2bca75bc20f7392d7887dfc2d132a9e23860","user":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":50695589,"node_id":"MDEwOlJlcG9zaXRvcnk1MDY5NTU4OQ==","name":"activity-stream","full_name":"mozilla/activity-stream","owner":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/activity-stream","description":"A refreshed \"new tab page\" for Firefox","fork":false,"url":"https://api.github.com/repos/mozilla/activity-stream","forks_url":"https://api.github.com/repos/mozilla/activity-stream/forks","keys_url":"https://api.github.com/repos/mozilla/activity-stream/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/activity-stream/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/activity-stream/teams","hooks_url":"https://api.github.com/repos/mozilla/activity-stream/hooks","issue_events_url":"https://api.github.com/repos/mozilla/activity-stream/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/activity-stream/events","assignees_url":"https://api.github.com/repos/mozilla/activity-stream/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/activity-stream/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/activity-stream/tags","blobs_url":"https://api.github.com/repos/mozilla/activity-stream/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/activity-stream/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/activity-stream/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/activity-stream/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/activity-stream/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/activity-stream/languages","stargazers_url":"https://api.github.com/repos/mozilla/activity-stream/stargazers","contributors_url":"https://api.github.com/repos/mozilla/activity-stream/contributors","subscribers_url":"https://api.github.com/repos/mozilla/activity-stream/subscribers","subscription_url":"https://api.github.com/repos/mozilla/activity-stream/subscription","commits_url":"https://api.github.com/repos/mozilla/activity-stream/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/activity-stream/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/activity-stream/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/activity-stream/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/activity-stream/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/activity-stream/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/activity-stream/merges","archive_url":"https://api.github.com/repos/mozilla/activity-stream/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/activity-stream/downloads","issues_url":"https://api.github.com/repos/mozilla/activity-stream/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/activity-stream/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/activity-stream/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/activity-stream/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/activity-stream/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/activity-stream/releases{/id}","deployments_url":"https://api.github.com/repos/mozilla/activity-stream/deployments","created_at":"2016-01-29T22:28:26Z","updated_at":"2018-08-08T20:47:51Z","pushed_at":"2018-08-09T15:28:03Z","git_url":"git://github.com/mozilla/activity-stream.git","ssh_url":"git@github.com:mozilla/activity-stream.git","clone_url":"https://github.com/mozilla/activity-stream.git","svn_url":"https://github.com/mozilla/activity-stream","homepage":"","size":11209,"stargazers_count":157,"watchers_count":157,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":106,"mirror_url":null,"archived":false,"open_issues_count":14,"license":{"key":"mpl-2.0","name":"Mozilla Public License 2.0","spdx_id":"MPL-2.0","url":"https://api.github.com/licenses/mpl-2.0","node_id":"MDc6TGljZW5zZTE0"},"forks":106,"open_issues":14,"watchers":157,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276"},"html":{"href":"https://github.com/mozilla/activity-stream/pull/4276"},"issue":{"href":"https://api.github.com/repos/mozilla/activity-stream/issues/4276"},"comments":{"href":"https://api.github.com/repos/mozilla/activity-stream/issues/4276/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla/activity-stream/pulls/4276/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla/activity-stream/statuses/ce61c6a56a5f78d7a9bd0a0b74278e2bf2743b18"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"k88hudson"}}