{"action":"created","comment":{"url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/comments/221695410","pull_request_review_id":160407146,"id":221695410,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMTY5NTQxMA==","diff_hunk":"@@ -12,8 +13,10 @@ import {bindClientFunc} from './helpers';\n import {getProfilesByIds, getProfilesInChannel} from './users';\n import {getChannelAndMyMember, getMyChannelMember} from './channels';\n \n-export function deletePreferences(userId, preferences) {\n-    return async (dispatch, getState) => {\n+import type {GetStateFunc, DispatchFunc, ActionFunc} from '../types/actions';\n+\n+export function deletePreferences(userId: string, preferences: Object): ActionFunc {","path":"src/actions/preferences.js","position":15,"original_position":15,"commit_id":"a92a5dacf291aec2dce56685fa459ba0b4e48105","original_commit_id":"a92a5dacf291aec2dce56685fa459ba0b4e48105","user":{"login":"jespino","id":290303,"node_id":"MDQ6VXNlcjI5MDMwMw==","avatar_url":"https://avatars0.githubusercontent.com/u/290303?v=4","gravatar_id":"","url":"https://api.github.com/users/jespino","html_url":"https://github.com/jespino","followers_url":"https://api.github.com/users/jespino/followers","following_url":"https://api.github.com/users/jespino/following{/other_user}","gists_url":"https://api.github.com/users/jespino/gists{/gist_id}","starred_url":"https://api.github.com/users/jespino/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jespino/subscriptions","organizations_url":"https://api.github.com/users/jespino/orgs","repos_url":"https://api.github.com/users/jespino/repos","events_url":"https://api.github.com/users/jespino/events{/privacy}","received_events_url":"https://api.github.com/users/jespino/received_events","type":"User","site_admin":false},"body":"In general the PR is ok, but you are using `Object` and we prefer to avoid that. If you want we can define the Preferences type. In this case, the preferences is an array of \"Preference\" type, which is\r\n```\r\n{|\r\n  category: string\r\n  name: string\r\n  user_id: string\r\n  value: string\r\n|}\r\n```\r\n","created_at":"2018-10-01T17:40:22Z","updated_at":"2018-10-01T17:40:22Z","html_url":"https://github.com/mattermost/mattermost-redux/pull/659#discussion_r221695410","pull_request_url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/comments/221695410"},"html":{"href":"https://github.com/mattermost/mattermost-redux/pull/659#discussion_r221695410"},"pull_request":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659"}}},"pull_request":{"url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659","id":219437966,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE5NDM3OTY2","html_url":"https://github.com/mattermost/mattermost-redux/pull/659","diff_url":"https://github.com/mattermost/mattermost-redux/pull/659.diff","patch_url":"https://github.com/mattermost/mattermost-redux/pull/659.patch","issue_url":"https://api.github.com/repos/mattermost/mattermost-redux/issues/659","number":659,"state":"open","locked":false,"title":"MM-11044 Add flow annotations to preferences actions","user":{"login":"anchepiece","id":279146,"node_id":"MDQ6VXNlcjI3OTE0Ng==","avatar_url":"https://avatars2.githubusercontent.com/u/279146?v=4","gravatar_id":"","url":"https://api.github.com/users/anchepiece","html_url":"https://github.com/anchepiece","followers_url":"https://api.github.com/users/anchepiece/followers","following_url":"https://api.github.com/users/anchepiece/following{/other_user}","gists_url":"https://api.github.com/users/anchepiece/gists{/gist_id}","starred_url":"https://api.github.com/users/anchepiece/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anchepiece/subscriptions","organizations_url":"https://api.github.com/users/anchepiece/orgs","repos_url":"https://api.github.com/users/anchepiece/repos","events_url":"https://api.github.com/users/anchepiece/events{/privacy}","received_events_url":"https://api.github.com/users/anchepiece/received_events","type":"User","site_admin":false},"body":"#### Summary\r\nFlow type definitions added to preferences\r\n\r\n#### Ticket Link\r\nhttps://mattermost.atlassian.net/browse/MM-11044\r\nhttps://github.com/mattermost/mattermost-server/issues/9300\r\n\r\n#### Checklist\r\n- [X] Ran `make check-style` to check for style errors (required for all pull requests)\r\n- [X] Ran `make test` to ensure unit tests passed\r\n- [X] Ran `make flow` to ensure type checking passed\r\n\r\n#### Test Information\r\nThis PR was tested on: Ubuntu 18.04.1 LTS","created_at":"2018-10-01T16:29:13Z","updated_at":"2018-10-01T17:40:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b536fae45836fc416aa490638904bb87671570c8","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659/commits","review_comments_url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659/comments","review_comment_url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mattermost/mattermost-redux/issues/659/comments","statuses_url":"https://api.github.com/repos/mattermost/mattermost-redux/statuses/a92a5dacf291aec2dce56685fa459ba0b4e48105","head":{"label":"anchepiece:flow/migrate-preferences","ref":"flow/migrate-preferences","sha":"a92a5dacf291aec2dce56685fa459ba0b4e48105","user":{"login":"anchepiece","id":279146,"node_id":"MDQ6VXNlcjI3OTE0Ng==","avatar_url":"https://avatars2.githubusercontent.com/u/279146?v=4","gravatar_id":"","url":"https://api.github.com/users/anchepiece","html_url":"https://github.com/anchepiece","followers_url":"https://api.github.com/users/anchepiece/followers","following_url":"https://api.github.com/users/anchepiece/following{/other_user}","gists_url":"https://api.github.com/users/anchepiece/gists{/gist_id}","starred_url":"https://api.github.com/users/anchepiece/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anchepiece/subscriptions","organizations_url":"https://api.github.com/users/anchepiece/orgs","repos_url":"https://api.github.com/users/anchepiece/repos","events_url":"https://api.github.com/users/anchepiece/events{/privacy}","received_events_url":"https://api.github.com/users/anchepiece/received_events","type":"User","site_admin":false},"repo":{"id":151117323,"node_id":"MDEwOlJlcG9zaXRvcnkxNTExMTczMjM=","name":"mattermost-redux","full_name":"anchepiece/mattermost-redux","private":false,"owner":{"login":"anchepiece","id":279146,"node_id":"MDQ6VXNlcjI3OTE0Ng==","avatar_url":"https://avatars2.githubusercontent.com/u/279146?v=4","gravatar_id":"","url":"https://api.github.com/users/anchepiece","html_url":"https://github.com/anchepiece","followers_url":"https://api.github.com/users/anchepiece/followers","following_url":"https://api.github.com/users/anchepiece/following{/other_user}","gists_url":"https://api.github.com/users/anchepiece/gists{/gist_id}","starred_url":"https://api.github.com/users/anchepiece/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anchepiece/subscriptions","organizations_url":"https://api.github.com/users/anchepiece/orgs","repos_url":"https://api.github.com/users/anchepiece/repos","events_url":"https://api.github.com/users/anchepiece/events{/privacy}","received_events_url":"https://api.github.com/users/anchepiece/received_events","type":"User","site_admin":false},"html_url":"https://github.com/anchepiece/mattermost-redux","description":"Redux for Mattermost","fork":true,"url":"https://api.github.com/repos/anchepiece/mattermost-redux","forks_url":"https://api.github.com/repos/anchepiece/mattermost-redux/forks","keys_url":"https://api.github.com/repos/anchepiece/mattermost-redux/keys{/key_id}","collaborators_url":"https://api.github.com/repos/anchepiece/mattermost-redux/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/anchepiece/mattermost-redux/teams","hooks_url":"https://api.github.com/repos/anchepiece/mattermost-redux/hooks","issue_events_url":"https://api.github.com/repos/anchepiece/mattermost-redux/issues/events{/number}","events_url":"https://api.github.com/repos/anchepiece/mattermost-redux/events","assignees_url":"https://api.github.com/repos/anchepiece/mattermost-redux/assignees{/user}","branches_url":"https://api.github.com/repos/anchepiece/mattermost-redux/branches{/branch}","tags_url":"https://api.github.com/repos/anchepiece/mattermost-redux/tags","blobs_url":"https://api.github.com/repos/anchepiece/mattermost-redux/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/anchepiece/mattermost-redux/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/anchepiece/mattermost-redux/git/refs{/sha}","trees_url":"https://api.github.com/repos/anchepiece/mattermost-redux/git/trees{/sha}","statuses_url":"https://api.github.com/repos/anchepiece/mattermost-redux/statuses/{sha}","languages_url":"https://api.github.com/repos/anchepiece/mattermost-redux/languages","stargazers_url":"https://api.github.com/repos/anchepiece/mattermost-redux/stargazers","contributors_url":"https://api.github.com/repos/anchepiece/mattermost-redux/contributors","subscribers_url":"https://api.github.com/repos/anchepiece/mattermost-redux/subscribers","subscription_url":"https://api.github.com/repos/anchepiece/mattermost-redux/subscription","commits_url":"https://api.github.com/repos/anchepiece/mattermost-redux/commits{/sha}","git_commits_url":"https://api.github.com/repos/anchepiece/mattermost-redux/git/commits{/sha}","comments_url":"https://api.github.com/repos/anchepiece/mattermost-redux/comments{/number}","issue_comment_url":"https://api.github.com/repos/anchepiece/mattermost-redux/issues/comments{/number}","contents_url":"https://api.github.com/repos/anchepiece/mattermost-redux/contents/{+path}","compare_url":"https://api.github.com/repos/anchepiece/mattermost-redux/compare/{base}...{head}","merges_url":"https://api.github.com/repos/anchepiece/mattermost-redux/merges","archive_url":"https://api.github.com/repos/anchepiece/mattermost-redux/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/anchepiece/mattermost-redux/downloads","issues_url":"https://api.github.com/repos/anchepiece/mattermost-redux/issues{/number}","pulls_url":"https://api.github.com/repos/anchepiece/mattermost-redux/pulls{/number}","milestones_url":"https://api.github.com/repos/anchepiece/mattermost-redux/milestones{/number}","notifications_url":"https://api.github.com/repos/anchepiece/mattermost-redux/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/anchepiece/mattermost-redux/labels{/name}","releases_url":"https://api.github.com/repos/anchepiece/mattermost-redux/releases{/id}","deployments_url":"https://api.github.com/repos/anchepiece/mattermost-redux/deployments","created_at":"2018-10-01T16:07:03Z","updated_at":"2018-10-01T16:07:06Z","pushed_at":"2018-10-01T16:25:33Z","git_url":"git://github.com/anchepiece/mattermost-redux.git","ssh_url":"git@github.com:anchepiece/mattermost-redux.git","clone_url":"https://github.com/anchepiece/mattermost-redux.git","svn_url":"https://github.com/anchepiece/mattermost-redux","homepage":null,"size":2157,"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":"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":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mattermost:master","ref":"master","sha":"887a8c40b08dfb80cbf74b503ef1a0562bac8396","user":{"login":"mattermost","id":9828093,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk4MjgwOTM=","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":84744614,"node_id":"MDEwOlJlcG9zaXRvcnk4NDc0NDYxNA==","name":"mattermost-redux","full_name":"mattermost/mattermost-redux","private":false,"owner":{"login":"mattermost","id":9828093,"node_id":"MDEyOk9yZ2FuaXphdGlvbjk4MjgwOTM=","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},"html_url":"https://github.com/mattermost/mattermost-redux","description":"Redux for Mattermost","fork":false,"url":"https://api.github.com/repos/mattermost/mattermost-redux","forks_url":"https://api.github.com/repos/mattermost/mattermost-redux/forks","keys_url":"https://api.github.com/repos/mattermost/mattermost-redux/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mattermost/mattermost-redux/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mattermost/mattermost-redux/teams","hooks_url":"https://api.github.com/repos/mattermost/mattermost-redux/hooks","issue_events_url":"https://api.github.com/repos/mattermost/mattermost-redux/issues/events{/number}","events_url":"https://api.github.com/repos/mattermost/mattermost-redux/events","assignees_url":"https://api.github.com/repos/mattermost/mattermost-redux/assignees{/user}","branches_url":"https://api.github.com/repos/mattermost/mattermost-redux/branches{/branch}","tags_url":"https://api.github.com/repos/mattermost/mattermost-redux/tags","blobs_url":"https://api.github.com/repos/mattermost/mattermost-redux/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mattermost/mattermost-redux/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mattermost/mattermost-redux/git/refs{/sha}","trees_url":"https://api.github.com/repos/mattermost/mattermost-redux/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mattermost/mattermost-redux/statuses/{sha}","languages_url":"https://api.github.com/repos/mattermost/mattermost-redux/languages","stargazers_url":"https://api.github.com/repos/mattermost/mattermost-redux/stargazers","contributors_url":"https://api.github.com/repos/mattermost/mattermost-redux/contributors","subscribers_url":"https://api.github.com/repos/mattermost/mattermost-redux/subscribers","subscription_url":"https://api.github.com/repos/mattermost/mattermost-redux/subscription","commits_url":"https://api.github.com/repos/mattermost/mattermost-redux/commits{/sha}","git_commits_url":"https://api.github.com/repos/mattermost/mattermost-redux/git/commits{/sha}","comments_url":"https://api.github.com/repos/mattermost/mattermost-redux/comments{/number}","issue_comment_url":"https://api.github.com/repos/mattermost/mattermost-redux/issues/comments{/number}","contents_url":"https://api.github.com/repos/mattermost/mattermost-redux/contents/{+path}","compare_url":"https://api.github.com/repos/mattermost/mattermost-redux/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mattermost/mattermost-redux/merges","archive_url":"https://api.github.com/repos/mattermost/mattermost-redux/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mattermost/mattermost-redux/downloads","issues_url":"https://api.github.com/repos/mattermost/mattermost-redux/issues{/number}","pulls_url":"https://api.github.com/repos/mattermost/mattermost-redux/pulls{/number}","milestones_url":"https://api.github.com/repos/mattermost/mattermost-redux/milestones{/number}","notifications_url":"https://api.github.com/repos/mattermost/mattermost-redux/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mattermost/mattermost-redux/labels{/name}","releases_url":"https://api.github.com/repos/mattermost/mattermost-redux/releases{/id}","deployments_url":"https://api.github.com/repos/mattermost/mattermost-redux/deployments","created_at":"2017-03-12T17:40:39Z","updated_at":"2018-10-01T15:22:00Z","pushed_at":"2018-10-01T16:29:14Z","git_url":"git://github.com/mattermost/mattermost-redux.git","ssh_url":"git@github.com:mattermost/mattermost-redux.git","clone_url":"https://github.com/mattermost/mattermost-redux.git","svn_url":"https://github.com/mattermost/mattermost-redux","homepage":null,"size":2155,"stargazers_count":76,"watchers_count":76,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":123,"mirror_url":null,"archived":false,"open_issues_count":17,"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":123,"open_issues":17,"watchers":76,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659"},"html":{"href":"https://github.com/mattermost/mattermost-redux/pull/659"},"issue":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/issues/659"},"comments":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/issues/659/comments"},"review_comments":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659/comments"},"review_comment":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/pulls/659/commits"},"statuses":{"href":"https://api.github.com/repos/mattermost/mattermost-redux/statuses/a92a5dacf291aec2dce56685fa459ba0b4e48105"}},"author_association":"NONE"}}
{"actor":{"display_login":"jespino"}}