{"action":"created","comment":{"url":"https://api.github.com/repos/wolox-training/gp-react/pulls/comments/234668214","pull_request_review_id":176345796,"id":234668214,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNDY2ODIxNA==","diff_hunk":"@@ -0,0 +1,63 @@\n+import UserService from '@services/UserService.js';\n+import { MSG_UNKNOWN_ID, ERROR_READING_RESPONSE, ERROR_LOGIN_SERVICE } from '@screens/Login/validation';\n+\n+export const actionTypes = {\n+  LOGIN: 'LOGIN',\n+  LOGIN_SUCCESS: 'LOGIN_SUCCESS',\n+  LOGIN_FAILURE: 'LOGIN_FAILURE'\n+};\n+\n+export const actionsCreators = {\n+  login: (username, password) => async dispatch => {\n+    dispatch({ type: actionTypes.LOGIN });\n+    const response = await UserService.login(username, password);\n+    if (response && response.data) {\n+      if (response.ok) {\n+        const userIsLogged = true;\n+        const userLoginError = null;\n+        const userSession = response.data.id || MSG_UNKNOWN_ID;\n+        localStorage.setItem('userIsLogged', true.toString());","path":"react/react-training/src/redux/login/actions.js","position":19,"original_position":19,"commit_id":"0a5e9b13f52e9b0867cfce5753f29487d0950f2e","original_commit_id":"0a5e9b13f52e9b0867cfce5753f29487d0950f2e","user":{"login":"henryzarza","id":28515670,"node_id":"MDQ6VXNlcjI4NTE1Njcw","avatar_url":"https://avatars3.githubusercontent.com/u/28515670?v=4","gravatar_id":"","url":"https://api.github.com/users/henryzarza","html_url":"https://github.com/henryzarza","followers_url":"https://api.github.com/users/henryzarza/followers","following_url":"https://api.github.com/users/henryzarza/following{/other_user}","gists_url":"https://api.github.com/users/henryzarza/gists{/gist_id}","starred_url":"https://api.github.com/users/henryzarza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/henryzarza/subscriptions","organizations_url":"https://api.github.com/users/henryzarza/orgs","repos_url":"https://api.github.com/users/henryzarza/repos","events_url":"https://api.github.com/users/henryzarza/events{/privacy}","received_events_url":"https://api.github.com/users/henryzarza/received_events","type":"User","site_admin":false},"body":"You can replace this for: `localStorage.setItem('userIsLogged', userIsLogged);`","created_at":"2018-11-19T15:41:01Z","updated_at":"2018-11-19T15:51:11Z","html_url":"https://github.com/wolox-training/gp-react/pull/23#discussion_r234668214","pull_request_url":"https://api.github.com/repos/wolox-training/gp-react/pulls/23","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/comments/234668214"},"html":{"href":"https://github.com/wolox-training/gp-react/pull/23#discussion_r234668214"},"pull_request":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/23"}}},"pull_request":{"url":"https://api.github.com/repos/wolox-training/gp-react/pulls/23","id":231343724,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMxMzQzNzI0","html_url":"https://github.com/wolox-training/gp-react/pull/23","diff_url":"https://github.com/wolox-training/gp-react/pull/23.diff","patch_url":"https://github.com/wolox-training/gp-react/pull/23.patch","issue_url":"https://api.github.com/repos/wolox-training/gp-react/issues/23","number":23,"state":"open","locked":false,"title":"16: Routing I - Login (Part 4)","user":{"login":"gabrielizalo","id":656353,"node_id":"MDQ6VXNlcjY1NjM1Mw==","avatar_url":"https://avatars2.githubusercontent.com/u/656353?v=4","gravatar_id":"","url":"https://api.github.com/users/gabrielizalo","html_url":"https://github.com/gabrielizalo","followers_url":"https://api.github.com/users/gabrielizalo/followers","following_url":"https://api.github.com/users/gabrielizalo/following{/other_user}","gists_url":"https://api.github.com/users/gabrielizalo/gists{/gist_id}","starred_url":"https://api.github.com/users/gabrielizalo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gabrielizalo/subscriptions","organizations_url":"https://api.github.com/users/gabrielizalo/orgs","repos_url":"https://api.github.com/users/gabrielizalo/repos","events_url":"https://api.github.com/users/gabrielizalo/events{/privacy}","received_events_url":"https://api.github.com/users/gabrielizalo/received_events","type":"User","site_admin":false},"body":"# Summary\r\n\r\n* Fourth task of Routing: Redux form del login\r\n   LocalStorage Integration.\r\n\r\n\r\n# Trello Card\r\n\r\nhttps://trello.com/c/uRUucKHu/9-routing-i-login\r\n\r\n\r\n# Screenshot\r\n\r\n<img width=\"1678\" alt=\"gabo s tic tac toe with localstorage\" src=\"https://user-images.githubusercontent.com/656353/48583523-5544bd80-e8f5-11e8-945b-37b10609861e.png\">\r\n\r\n","created_at":"2018-11-15T21:42:14Z","updated_at":"2018-11-19T15:51:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1ffde10f59a55a1784ef378e8ec2b94a70c6742b","assignee":{"login":"WFolini","id":12822259,"node_id":"MDQ6VXNlcjEyODIyMjU5","avatar_url":"https://avatars2.githubusercontent.com/u/12822259?v=4","gravatar_id":"","url":"https://api.github.com/users/WFolini","html_url":"https://github.com/WFolini","followers_url":"https://api.github.com/users/WFolini/followers","following_url":"https://api.github.com/users/WFolini/following{/other_user}","gists_url":"https://api.github.com/users/WFolini/gists{/gist_id}","starred_url":"https://api.github.com/users/WFolini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WFolini/subscriptions","organizations_url":"https://api.github.com/users/WFolini/orgs","repos_url":"https://api.github.com/users/WFolini/repos","events_url":"https://api.github.com/users/WFolini/events{/privacy}","received_events_url":"https://api.github.com/users/WFolini/received_events","type":"User","site_admin":false},"assignees":[{"login":"WFolini","id":12822259,"node_id":"MDQ6VXNlcjEyODIyMjU5","avatar_url":"https://avatars2.githubusercontent.com/u/12822259?v=4","gravatar_id":"","url":"https://api.github.com/users/WFolini","html_url":"https://github.com/WFolini","followers_url":"https://api.github.com/users/WFolini/followers","following_url":"https://api.github.com/users/WFolini/following{/other_user}","gists_url":"https://api.github.com/users/WFolini/gists{/gist_id}","starred_url":"https://api.github.com/users/WFolini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WFolini/subscriptions","organizations_url":"https://api.github.com/users/WFolini/orgs","repos_url":"https://api.github.com/users/WFolini/repos","events_url":"https://api.github.com/users/WFolini/events{/privacy}","received_events_url":"https://api.github.com/users/WFolini/received_events","type":"User","site_admin":false},{"login":"henryzarza","id":28515670,"node_id":"MDQ6VXNlcjI4NTE1Njcw","avatar_url":"https://avatars3.githubusercontent.com/u/28515670?v=4","gravatar_id":"","url":"https://api.github.com/users/henryzarza","html_url":"https://github.com/henryzarza","followers_url":"https://api.github.com/users/henryzarza/followers","following_url":"https://api.github.com/users/henryzarza/following{/other_user}","gists_url":"https://api.github.com/users/henryzarza/gists{/gist_id}","starred_url":"https://api.github.com/users/henryzarza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/henryzarza/subscriptions","organizations_url":"https://api.github.com/users/henryzarza/orgs","repos_url":"https://api.github.com/users/henryzarza/repos","events_url":"https://api.github.com/users/henryzarza/events{/privacy}","received_events_url":"https://api.github.com/users/henryzarza/received_events","type":"User","site_admin":false}],"requested_reviewers":[{"login":"WFolini","id":12822259,"node_id":"MDQ6VXNlcjEyODIyMjU5","avatar_url":"https://avatars2.githubusercontent.com/u/12822259?v=4","gravatar_id":"","url":"https://api.github.com/users/WFolini","html_url":"https://github.com/WFolini","followers_url":"https://api.github.com/users/WFolini/followers","following_url":"https://api.github.com/users/WFolini/following{/other_user}","gists_url":"https://api.github.com/users/WFolini/gists{/gist_id}","starred_url":"https://api.github.com/users/WFolini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WFolini/subscriptions","organizations_url":"https://api.github.com/users/WFolini/orgs","repos_url":"https://api.github.com/users/WFolini/repos","events_url":"https://api.github.com/users/WFolini/events{/privacy}","received_events_url":"https://api.github.com/users/WFolini/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/wolox-training/gp-react/pulls/23/commits","review_comments_url":"https://api.github.com/repos/wolox-training/gp-react/pulls/23/comments","review_comment_url":"https://api.github.com/repos/wolox-training/gp-react/pulls/comments{/number}","comments_url":"https://api.github.com/repos/wolox-training/gp-react/issues/23/comments","statuses_url":"https://api.github.com/repos/wolox-training/gp-react/statuses/0a5e9b13f52e9b0867cfce5753f29487d0950f2e","head":{"label":"wolox-training:16-Routing-I-Login-Part4","ref":"16-Routing-I-Login-Part4","sha":"0a5e9b13f52e9b0867cfce5753f29487d0950f2e","user":{"login":"wolox-training","id":14113351,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTEzMzUx","avatar_url":"https://avatars1.githubusercontent.com/u/14113351?v=4","gravatar_id":"","url":"https://api.github.com/users/wolox-training","html_url":"https://github.com/wolox-training","followers_url":"https://api.github.com/users/wolox-training/followers","following_url":"https://api.github.com/users/wolox-training/following{/other_user}","gists_url":"https://api.github.com/users/wolox-training/gists{/gist_id}","starred_url":"https://api.github.com/users/wolox-training/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolox-training/subscriptions","organizations_url":"https://api.github.com/users/wolox-training/orgs","repos_url":"https://api.github.com/users/wolox-training/repos","events_url":"https://api.github.com/users/wolox-training/events{/privacy}","received_events_url":"https://api.github.com/users/wolox-training/received_events","type":"Organization","site_admin":false},"repo":{"id":150106305,"node_id":"MDEwOlJlcG9zaXRvcnkxNTAxMDYzMDU=","name":"gp-react","full_name":"wolox-training/gp-react","private":false,"owner":{"login":"wolox-training","id":14113351,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTEzMzUx","avatar_url":"https://avatars1.githubusercontent.com/u/14113351?v=4","gravatar_id":"","url":"https://api.github.com/users/wolox-training","html_url":"https://github.com/wolox-training","followers_url":"https://api.github.com/users/wolox-training/followers","following_url":"https://api.github.com/users/wolox-training/following{/other_user}","gists_url":"https://api.github.com/users/wolox-training/gists{/gist_id}","starred_url":"https://api.github.com/users/wolox-training/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolox-training/subscriptions","organizations_url":"https://api.github.com/users/wolox-training/orgs","repos_url":"https://api.github.com/users/wolox-training/repos","events_url":"https://api.github.com/users/wolox-training/events{/privacy}","received_events_url":"https://api.github.com/users/wolox-training/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/wolox-training/gp-react","description":null,"fork":false,"url":"https://api.github.com/repos/wolox-training/gp-react","forks_url":"https://api.github.com/repos/wolox-training/gp-react/forks","keys_url":"https://api.github.com/repos/wolox-training/gp-react/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wolox-training/gp-react/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wolox-training/gp-react/teams","hooks_url":"https://api.github.com/repos/wolox-training/gp-react/hooks","issue_events_url":"https://api.github.com/repos/wolox-training/gp-react/issues/events{/number}","events_url":"https://api.github.com/repos/wolox-training/gp-react/events","assignees_url":"https://api.github.com/repos/wolox-training/gp-react/assignees{/user}","branches_url":"https://api.github.com/repos/wolox-training/gp-react/branches{/branch}","tags_url":"https://api.github.com/repos/wolox-training/gp-react/tags","blobs_url":"https://api.github.com/repos/wolox-training/gp-react/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wolox-training/gp-react/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wolox-training/gp-react/git/refs{/sha}","trees_url":"https://api.github.com/repos/wolox-training/gp-react/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wolox-training/gp-react/statuses/{sha}","languages_url":"https://api.github.com/repos/wolox-training/gp-react/languages","stargazers_url":"https://api.github.com/repos/wolox-training/gp-react/stargazers","contributors_url":"https://api.github.com/repos/wolox-training/gp-react/contributors","subscribers_url":"https://api.github.com/repos/wolox-training/gp-react/subscribers","subscription_url":"https://api.github.com/repos/wolox-training/gp-react/subscription","commits_url":"https://api.github.com/repos/wolox-training/gp-react/commits{/sha}","git_commits_url":"https://api.github.com/repos/wolox-training/gp-react/git/commits{/sha}","comments_url":"https://api.github.com/repos/wolox-training/gp-react/comments{/number}","issue_comment_url":"https://api.github.com/repos/wolox-training/gp-react/issues/comments{/number}","contents_url":"https://api.github.com/repos/wolox-training/gp-react/contents/{+path}","compare_url":"https://api.github.com/repos/wolox-training/gp-react/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wolox-training/gp-react/merges","archive_url":"https://api.github.com/repos/wolox-training/gp-react/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wolox-training/gp-react/downloads","issues_url":"https://api.github.com/repos/wolox-training/gp-react/issues{/number}","pulls_url":"https://api.github.com/repos/wolox-training/gp-react/pulls{/number}","milestones_url":"https://api.github.com/repos/wolox-training/gp-react/milestones{/number}","notifications_url":"https://api.github.com/repos/wolox-training/gp-react/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wolox-training/gp-react/labels{/name}","releases_url":"https://api.github.com/repos/wolox-training/gp-react/releases{/id}","deployments_url":"https://api.github.com/repos/wolox-training/gp-react/deployments","created_at":"2018-09-24T13:24:11Z","updated_at":"2018-11-15T19:19:27Z","pushed_at":"2018-11-15T21:42:14Z","git_url":"git://github.com/wolox-training/gp-react.git","ssh_url":"git@github.com:wolox-training/gp-react.git","clone_url":"https://github.com/wolox-training/gp-react.git","svn_url":"https://github.com/wolox-training/gp-react","homepage":null,"size":718,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"wolox-training:master","ref":"master","sha":"e5f1c7da9372fd531d191ba14e487479b2953d5a","user":{"login":"wolox-training","id":14113351,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTEzMzUx","avatar_url":"https://avatars1.githubusercontent.com/u/14113351?v=4","gravatar_id":"","url":"https://api.github.com/users/wolox-training","html_url":"https://github.com/wolox-training","followers_url":"https://api.github.com/users/wolox-training/followers","following_url":"https://api.github.com/users/wolox-training/following{/other_user}","gists_url":"https://api.github.com/users/wolox-training/gists{/gist_id}","starred_url":"https://api.github.com/users/wolox-training/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolox-training/subscriptions","organizations_url":"https://api.github.com/users/wolox-training/orgs","repos_url":"https://api.github.com/users/wolox-training/repos","events_url":"https://api.github.com/users/wolox-training/events{/privacy}","received_events_url":"https://api.github.com/users/wolox-training/received_events","type":"Organization","site_admin":false},"repo":{"id":150106305,"node_id":"MDEwOlJlcG9zaXRvcnkxNTAxMDYzMDU=","name":"gp-react","full_name":"wolox-training/gp-react","private":false,"owner":{"login":"wolox-training","id":14113351,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTEzMzUx","avatar_url":"https://avatars1.githubusercontent.com/u/14113351?v=4","gravatar_id":"","url":"https://api.github.com/users/wolox-training","html_url":"https://github.com/wolox-training","followers_url":"https://api.github.com/users/wolox-training/followers","following_url":"https://api.github.com/users/wolox-training/following{/other_user}","gists_url":"https://api.github.com/users/wolox-training/gists{/gist_id}","starred_url":"https://api.github.com/users/wolox-training/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolox-training/subscriptions","organizations_url":"https://api.github.com/users/wolox-training/orgs","repos_url":"https://api.github.com/users/wolox-training/repos","events_url":"https://api.github.com/users/wolox-training/events{/privacy}","received_events_url":"https://api.github.com/users/wolox-training/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/wolox-training/gp-react","description":null,"fork":false,"url":"https://api.github.com/repos/wolox-training/gp-react","forks_url":"https://api.github.com/repos/wolox-training/gp-react/forks","keys_url":"https://api.github.com/repos/wolox-training/gp-react/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wolox-training/gp-react/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wolox-training/gp-react/teams","hooks_url":"https://api.github.com/repos/wolox-training/gp-react/hooks","issue_events_url":"https://api.github.com/repos/wolox-training/gp-react/issues/events{/number}","events_url":"https://api.github.com/repos/wolox-training/gp-react/events","assignees_url":"https://api.github.com/repos/wolox-training/gp-react/assignees{/user}","branches_url":"https://api.github.com/repos/wolox-training/gp-react/branches{/branch}","tags_url":"https://api.github.com/repos/wolox-training/gp-react/tags","blobs_url":"https://api.github.com/repos/wolox-training/gp-react/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wolox-training/gp-react/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wolox-training/gp-react/git/refs{/sha}","trees_url":"https://api.github.com/repos/wolox-training/gp-react/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wolox-training/gp-react/statuses/{sha}","languages_url":"https://api.github.com/repos/wolox-training/gp-react/languages","stargazers_url":"https://api.github.com/repos/wolox-training/gp-react/stargazers","contributors_url":"https://api.github.com/repos/wolox-training/gp-react/contributors","subscribers_url":"https://api.github.com/repos/wolox-training/gp-react/subscribers","subscription_url":"https://api.github.com/repos/wolox-training/gp-react/subscription","commits_url":"https://api.github.com/repos/wolox-training/gp-react/commits{/sha}","git_commits_url":"https://api.github.com/repos/wolox-training/gp-react/git/commits{/sha}","comments_url":"https://api.github.com/repos/wolox-training/gp-react/comments{/number}","issue_comment_url":"https://api.github.com/repos/wolox-training/gp-react/issues/comments{/number}","contents_url":"https://api.github.com/repos/wolox-training/gp-react/contents/{+path}","compare_url":"https://api.github.com/repos/wolox-training/gp-react/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wolox-training/gp-react/merges","archive_url":"https://api.github.com/repos/wolox-training/gp-react/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wolox-training/gp-react/downloads","issues_url":"https://api.github.com/repos/wolox-training/gp-react/issues{/number}","pulls_url":"https://api.github.com/repos/wolox-training/gp-react/pulls{/number}","milestones_url":"https://api.github.com/repos/wolox-training/gp-react/milestones{/number}","notifications_url":"https://api.github.com/repos/wolox-training/gp-react/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wolox-training/gp-react/labels{/name}","releases_url":"https://api.github.com/repos/wolox-training/gp-react/releases{/id}","deployments_url":"https://api.github.com/repos/wolox-training/gp-react/deployments","created_at":"2018-09-24T13:24:11Z","updated_at":"2018-11-15T19:19:27Z","pushed_at":"2018-11-15T21:42:14Z","git_url":"git://github.com/wolox-training/gp-react.git","ssh_url":"git@github.com:wolox-training/gp-react.git","clone_url":"https://github.com/wolox-training/gp-react.git","svn_url":"https://github.com/wolox-training/gp-react","homepage":null,"size":718,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/23"},"html":{"href":"https://github.com/wolox-training/gp-react/pull/23"},"issue":{"href":"https://api.github.com/repos/wolox-training/gp-react/issues/23"},"comments":{"href":"https://api.github.com/repos/wolox-training/gp-react/issues/23/comments"},"review_comments":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/23/comments"},"review_comment":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/wolox-training/gp-react/pulls/23/commits"},"statuses":{"href":"https://api.github.com/repos/wolox-training/gp-react/statuses/0a5e9b13f52e9b0867cfce5753f29487d0950f2e"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"henryzarza"}}