{"action":"created","comment":{"url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/comments/153263744","pull_request_review_id":79244359,"id":153263744,"diff_hunk":"@@ -160,15 +149,8 @@ export default class NeedsTeam extends React.Component {\n         document.addEventListener('keydown', this.shortcutKeyDown);\n     }\n \n-    componentDidUpdate(prevProps, prevState) {\n-        if (!Utils.areObjectsEqual(prevState.theme, this.state.theme)) {\n-            Utils.applyTheme(this.state.theme);","path":"components/needs_team/needs_team.jsx","position":88,"original_position":96,"commit_id":"79b9e199bccb9d6aaabb32274e39ac23472bd6b8","original_commit_id":"5fc2201f36634328db9b6e0adce5e62a5011c527","user":{"login":"hmhealey","id":3277310,"avatar_url":"https://avatars3.githubusercontent.com/u/3277310?v=4","gravatar_id":"","url":"https://api.github.com/users/hmhealey","html_url":"https://github.com/hmhealey","followers_url":"https://api.github.com/users/hmhealey/followers","following_url":"https://api.github.com/users/hmhealey/following{/other_user}","gists_url":"https://api.github.com/users/hmhealey/gists{/gist_id}","starred_url":"https://api.github.com/users/hmhealey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hmhealey/subscriptions","organizations_url":"https://api.github.com/users/hmhealey/orgs","repos_url":"https://api.github.com/users/hmhealey/repos","events_url":"https://api.github.com/users/hmhealey/events{/privacy}","received_events_url":"https://api.github.com/users/hmhealey/received_events","type":"User","site_admin":false},"body":"That's a good point that it should be slightly more efficient, but I think any gains would be negligible, so I'd rather stick with convention for the time being, even if it's not the best. As it is, the only thing remaining in state is the current team (which really should be passed in through props, but that's beside the point), so it'll still be rare that a state change triggers this when it doesn't need to. Also, since `getTheme` is a selector, you can also change the check to be `if (nextProps.theme !== this.props.theme)` to make it virtually free\r\n\r\nI'd be open to changing our convention here, but unless we make the decision to do it everywhere, I'd rather we keep this code working the same way.","created_at":"2017-11-27T17:18:00Z","updated_at":"2017-11-27T17:18:00Z","html_url":"https://github.com/mattermost/mattermost-webapp/pull/337#discussion_r153263744","pull_request_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/comments/153263744"},"html":{"href":"https://github.com/mattermost/mattermost-webapp/pull/337#discussion_r153263744"},"pull_request":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337"}},"in_reply_to_id":152307477},"pull_request":{"url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337","id":153769812,"html_url":"https://github.com/mattermost/mattermost-webapp/pull/337","diff_url":"https://github.com/mattermost/mattermost-webapp/pull/337.diff","patch_url":"https://github.com/mattermost/mattermost-webapp/pull/337.patch","issue_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/337","number":337,"state":"open","locked":false,"title":"PLT-2068: Switching to use Redux getTheme selector.","user":{"login":"mkraft","id":1149597,"avatar_url":"https://avatars1.githubusercontent.com/u/1149597?v=4","gravatar_id":"","url":"https://api.github.com/users/mkraft","html_url":"https://github.com/mkraft","followers_url":"https://api.github.com/users/mkraft/followers","following_url":"https://api.github.com/users/mkraft/following{/other_user}","gists_url":"https://api.github.com/users/mkraft/gists{/gist_id}","starred_url":"https://api.github.com/users/mkraft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mkraft/subscriptions","organizations_url":"https://api.github.com/users/mkraft/orgs","repos_url":"https://api.github.com/users/mkraft/repos","events_url":"https://api.github.com/users/mkraft/events{/privacy}","received_events_url":"https://api.github.com/users/mkraft/received_events","type":"User","site_admin":false},"body":"#### Summary\r\nRemoves a few more references to the old `PreferenceStore.getTheme(teamId)`. There is one final reference still present that can be eliminated when `ThemeSetting` is migrated to Redux (in another story).\r\n\r\n#### Ticket Link\r\nDone related to [PLT-2068](https://mattermost.atlassian.net/browse/PLT-2068) (but not required for it).\r\n\r\n#### Checklist\r\n- [x] Ran `make check-style` to check for style errors\r\n- [x] Ran `make test` to ensure unit and component tests passed\r\n- [x] Has redux changes [link to redux change](https://github.com/mattermost/mattermost-redux/pull/329)","created_at":"2017-11-21T00:35:45Z","updated_at":"2017-11-27T17:18:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5f1bdca8c0580b4945dbb0ea1fb27d95e05a0949","assignee":{"login":"hmhealey","id":3277310,"avatar_url":"https://avatars3.githubusercontent.com/u/3277310?v=4","gravatar_id":"","url":"https://api.github.com/users/hmhealey","html_url":"https://github.com/hmhealey","followers_url":"https://api.github.com/users/hmhealey/followers","following_url":"https://api.github.com/users/hmhealey/following{/other_user}","gists_url":"https://api.github.com/users/hmhealey/gists{/gist_id}","starred_url":"https://api.github.com/users/hmhealey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hmhealey/subscriptions","organizations_url":"https://api.github.com/users/hmhealey/orgs","repos_url":"https://api.github.com/users/hmhealey/repos","events_url":"https://api.github.com/users/hmhealey/events{/privacy}","received_events_url":"https://api.github.com/users/hmhealey/received_events","type":"User","site_admin":false},"assignees":[{"login":"hmhealey","id":3277310,"avatar_url":"https://avatars3.githubusercontent.com/u/3277310?v=4","gravatar_id":"","url":"https://api.github.com/users/hmhealey","html_url":"https://github.com/hmhealey","followers_url":"https://api.github.com/users/hmhealey/followers","following_url":"https://api.github.com/users/hmhealey/following{/other_user}","gists_url":"https://api.github.com/users/hmhealey/gists{/gist_id}","starred_url":"https://api.github.com/users/hmhealey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hmhealey/subscriptions","organizations_url":"https://api.github.com/users/hmhealey/orgs","repos_url":"https://api.github.com/users/hmhealey/repos","events_url":"https://api.github.com/users/hmhealey/events{/privacy}","received_events_url":"https://api.github.com/users/hmhealey/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337/commits","review_comments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337/comments","review_comment_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/337/comments","statuses_url":"https://api.github.com/repos/mattermost/mattermost-webapp/statuses/79b9e199bccb9d6aaabb32274e39ac23472bd6b8","head":{"label":"mattermost:PLT-2068","ref":"PLT-2068","sha":"79b9e199bccb9d6aaabb32274e39ac23472bd6b8","user":{"login":"mattermost","id":9828093,"avatar_url":"https://avatars1.githubusercontent.com/u/9828093?v=4","gravatar_id":"","url":"https://api.github.com/users/mattermost","html_url":"https://github.com/mattermost","followers_url":"https://api.github.com/users/mattermost/followers","following_url":"https://api.github.com/users/mattermost/following{/other_user}","gists_url":"https://api.github.com/users/mattermost/gists{/gist_id}","starred_url":"https://api.github.com/users/mattermost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattermost/subscriptions","organizations_url":"https://api.github.com/users/mattermost/orgs","repos_url":"https://api.github.com/users/mattermost/repos","events_url":"https://api.github.com/users/mattermost/events{/privacy}","received_events_url":"https://api.github.com/users/mattermost/received_events","type":"Organization","site_admin":false},"repo":{"id":102689445,"name":"mattermost-webapp","full_name":"mattermost/mattermost-webapp","owner":{"login":"mattermost","id":9828093,"avatar_url":"https://avatars1.githubusercontent.com/u/9828093?v=4","gravatar_id":"","url":"https://api.github.com/users/mattermost","html_url":"https://github.com/mattermost","followers_url":"https://api.github.com/users/mattermost/followers","following_url":"https://api.github.com/users/mattermost/following{/other_user}","gists_url":"https://api.github.com/users/mattermost/gists{/gist_id}","starred_url":"https://api.github.com/users/mattermost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattermost/subscriptions","organizations_url":"https://api.github.com/users/mattermost/orgs","repos_url":"https://api.github.com/users/mattermost/repos","events_url":"https://api.github.com/users/mattermost/events{/privacy}","received_events_url":"https://api.github.com/users/mattermost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mattermost/mattermost-webapp","description":"Webapp of Mattermost server: https://github.com/mattermost/mattermost-server","fork":false,"url":"https://api.github.com/repos/mattermost/mattermost-webapp","forks_url":"https://api.github.com/repos/mattermost/mattermost-webapp/forks","keys_url":"https://api.github.com/repos/mattermost/mattermost-webapp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mattermost/mattermost-webapp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mattermost/mattermost-webapp/teams","hooks_url":"https://api.github.com/repos/mattermost/mattermost-webapp/hooks","issue_events_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/events{/number}","events_url":"https://api.github.com/repos/mattermost/mattermost-webapp/events","assignees_url":"https://api.github.com/repos/mattermost/mattermost-webapp/assignees{/user}","branches_url":"https://api.github.com/repos/mattermost/mattermost-webapp/branches{/branch}","tags_url":"https://api.github.com/repos/mattermost/mattermost-webapp/tags","blobs_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/refs{/sha}","trees_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mattermost/mattermost-webapp/statuses/{sha}","languages_url":"https://api.github.com/repos/mattermost/mattermost-webapp/languages","stargazers_url":"https://api.github.com/repos/mattermost/mattermost-webapp/stargazers","contributors_url":"https://api.github.com/repos/mattermost/mattermost-webapp/contributors","subscribers_url":"https://api.github.com/repos/mattermost/mattermost-webapp/subscribers","subscription_url":"https://api.github.com/repos/mattermost/mattermost-webapp/subscription","commits_url":"https://api.github.com/repos/mattermost/mattermost-webapp/commits{/sha}","git_commits_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/commits{/sha}","comments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/comments{/number}","issue_comment_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/comments{/number}","contents_url":"https://api.github.com/repos/mattermost/mattermost-webapp/contents/{+path}","compare_url":"https://api.github.com/repos/mattermost/mattermost-webapp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mattermost/mattermost-webapp/merges","archive_url":"https://api.github.com/repos/mattermost/mattermost-webapp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mattermost/mattermost-webapp/downloads","issues_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues{/number}","pulls_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls{/number}","milestones_url":"https://api.github.com/repos/mattermost/mattermost-webapp/milestones{/number}","notifications_url":"https://api.github.com/repos/mattermost/mattermost-webapp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mattermost/mattermost-webapp/labels{/name}","releases_url":"https://api.github.com/repos/mattermost/mattermost-webapp/releases{/id}","deployments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/deployments","created_at":"2017-09-07T04:00:02Z","updated_at":"2017-11-25T19:44:23Z","pushed_at":"2017-11-27T16:39:56Z","git_url":"git://github.com/mattermost/mattermost-webapp.git","ssh_url":"git@github.com:mattermost/mattermost-webapp.git","clone_url":"https://github.com/mattermost/mattermost-webapp.git","svn_url":"https://github.com/mattermost/mattermost-webapp","homepage":null,"size":75761,"stargazers_count":66,"watchers_count":66,"language":"JavaScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":153,"mirror_url":null,"archived":false,"open_issues_count":37,"forks":153,"open_issues":37,"watchers":66,"default_branch":"master"}},"base":{"label":"mattermost:master","ref":"master","sha":"70cecc31fb493a6f0ae7173eccf6df4350e281a0","user":{"login":"mattermost","id":9828093,"avatar_url":"https://avatars1.githubusercontent.com/u/9828093?v=4","gravatar_id":"","url":"https://api.github.com/users/mattermost","html_url":"https://github.com/mattermost","followers_url":"https://api.github.com/users/mattermost/followers","following_url":"https://api.github.com/users/mattermost/following{/other_user}","gists_url":"https://api.github.com/users/mattermost/gists{/gist_id}","starred_url":"https://api.github.com/users/mattermost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattermost/subscriptions","organizations_url":"https://api.github.com/users/mattermost/orgs","repos_url":"https://api.github.com/users/mattermost/repos","events_url":"https://api.github.com/users/mattermost/events{/privacy}","received_events_url":"https://api.github.com/users/mattermost/received_events","type":"Organization","site_admin":false},"repo":{"id":102689445,"name":"mattermost-webapp","full_name":"mattermost/mattermost-webapp","owner":{"login":"mattermost","id":9828093,"avatar_url":"https://avatars1.githubusercontent.com/u/9828093?v=4","gravatar_id":"","url":"https://api.github.com/users/mattermost","html_url":"https://github.com/mattermost","followers_url":"https://api.github.com/users/mattermost/followers","following_url":"https://api.github.com/users/mattermost/following{/other_user}","gists_url":"https://api.github.com/users/mattermost/gists{/gist_id}","starred_url":"https://api.github.com/users/mattermost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattermost/subscriptions","organizations_url":"https://api.github.com/users/mattermost/orgs","repos_url":"https://api.github.com/users/mattermost/repos","events_url":"https://api.github.com/users/mattermost/events{/privacy}","received_events_url":"https://api.github.com/users/mattermost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mattermost/mattermost-webapp","description":"Webapp of Mattermost server: https://github.com/mattermost/mattermost-server","fork":false,"url":"https://api.github.com/repos/mattermost/mattermost-webapp","forks_url":"https://api.github.com/repos/mattermost/mattermost-webapp/forks","keys_url":"https://api.github.com/repos/mattermost/mattermost-webapp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mattermost/mattermost-webapp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mattermost/mattermost-webapp/teams","hooks_url":"https://api.github.com/repos/mattermost/mattermost-webapp/hooks","issue_events_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/events{/number}","events_url":"https://api.github.com/repos/mattermost/mattermost-webapp/events","assignees_url":"https://api.github.com/repos/mattermost/mattermost-webapp/assignees{/user}","branches_url":"https://api.github.com/repos/mattermost/mattermost-webapp/branches{/branch}","tags_url":"https://api.github.com/repos/mattermost/mattermost-webapp/tags","blobs_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/refs{/sha}","trees_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mattermost/mattermost-webapp/statuses/{sha}","languages_url":"https://api.github.com/repos/mattermost/mattermost-webapp/languages","stargazers_url":"https://api.github.com/repos/mattermost/mattermost-webapp/stargazers","contributors_url":"https://api.github.com/repos/mattermost/mattermost-webapp/contributors","subscribers_url":"https://api.github.com/repos/mattermost/mattermost-webapp/subscribers","subscription_url":"https://api.github.com/repos/mattermost/mattermost-webapp/subscription","commits_url":"https://api.github.com/repos/mattermost/mattermost-webapp/commits{/sha}","git_commits_url":"https://api.github.com/repos/mattermost/mattermost-webapp/git/commits{/sha}","comments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/comments{/number}","issue_comment_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/comments{/number}","contents_url":"https://api.github.com/repos/mattermost/mattermost-webapp/contents/{+path}","compare_url":"https://api.github.com/repos/mattermost/mattermost-webapp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mattermost/mattermost-webapp/merges","archive_url":"https://api.github.com/repos/mattermost/mattermost-webapp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mattermost/mattermost-webapp/downloads","issues_url":"https://api.github.com/repos/mattermost/mattermost-webapp/issues{/number}","pulls_url":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls{/number}","milestones_url":"https://api.github.com/repos/mattermost/mattermost-webapp/milestones{/number}","notifications_url":"https://api.github.com/repos/mattermost/mattermost-webapp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mattermost/mattermost-webapp/labels{/name}","releases_url":"https://api.github.com/repos/mattermost/mattermost-webapp/releases{/id}","deployments_url":"https://api.github.com/repos/mattermost/mattermost-webapp/deployments","created_at":"2017-09-07T04:00:02Z","updated_at":"2017-11-25T19:44:23Z","pushed_at":"2017-11-27T16:39:56Z","git_url":"git://github.com/mattermost/mattermost-webapp.git","ssh_url":"git@github.com:mattermost/mattermost-webapp.git","clone_url":"https://github.com/mattermost/mattermost-webapp.git","svn_url":"https://github.com/mattermost/mattermost-webapp","homepage":null,"size":75761,"stargazers_count":66,"watchers_count":66,"language":"JavaScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":153,"mirror_url":null,"archived":false,"open_issues_count":37,"forks":153,"open_issues":37,"watchers":66,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337"},"html":{"href":"https://github.com/mattermost/mattermost-webapp/pull/337"},"issue":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/337"},"comments":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/issues/337/comments"},"review_comments":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337/comments"},"review_comment":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/pulls/337/commits"},"statuses":{"href":"https://api.github.com/repos/mattermost/mattermost-webapp/statuses/79b9e199bccb9d6aaabb32274e39ac23472bd6b8"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"hmhealey"}}