{"action":"created","comment":{"url":"https://api.github.com/repos/andela/elven-ah/pulls/comments/207632092","pull_request_review_id":143290744,"id":207632092,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwNzYzMjA5Mg==","diff_hunk":"@@ -15,4 +18,17 @@ userRouter.put('/', UserController.updateUser);\n \n userRouter.post('/login', UserController.login);\n \n+\n+// Password reset\n+userRouter.post('/account/password/reset',\n+  UserValidation.passwordResetValidation,\n+  PasswordResetController.sendResetEmail);\n+\n+userRouter.get('/account/password/reset', checkToken,\n+  PasswordResetController.verifyPasswordResetToken);\n+\n+userRouter.put('/account/password/reset', checkToken,","path":"server/routes/users.js","position":23,"original_position":23,"commit_id":"10b3aef20add18b52ea0c39e0970dd7921894536","original_commit_id":"10b3aef20add18b52ea0c39e0970dd7921894536","user":{"login":"houndci-bot","id":6697940,"node_id":"MDQ6VXNlcjY2OTc5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Expected a newline after '('   function-paren-newline","created_at":"2018-08-03T18:35:06Z","updated_at":"2018-08-03T18:35:07Z","html_url":"https://github.com/andela/elven-ah/pull/13#discussion_r207632092","pull_request_url":"https://api.github.com/repos/andela/elven-ah/pulls/13","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/comments/207632092"},"html":{"href":"https://github.com/andela/elven-ah/pull/13#discussion_r207632092"},"pull_request":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/13"}}},"pull_request":{"url":"https://api.github.com/repos/andela/elven-ah/pulls/13","id":206107294,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA2MTA3Mjk0","html_url":"https://github.com/andela/elven-ah/pull/13","diff_url":"https://github.com/andela/elven-ah/pull/13.diff","patch_url":"https://github.com/andela/elven-ah/pull/13.patch","issue_url":"https://api.github.com/repos/andela/elven-ah/issues/13","number":13,"state":"open","locked":false,"title":"#159204718 user reset password upon request","user":{"login":"yomigeek","id":5827585,"node_id":"MDQ6VXNlcjU4Mjc1ODU=","avatar_url":"https://avatars0.githubusercontent.com/u/5827585?v=4","gravatar_id":"","url":"https://api.github.com/users/yomigeek","html_url":"https://github.com/yomigeek","followers_url":"https://api.github.com/users/yomigeek/followers","following_url":"https://api.github.com/users/yomigeek/following{/other_user}","gists_url":"https://api.github.com/users/yomigeek/gists{/gist_id}","starred_url":"https://api.github.com/users/yomigeek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yomigeek/subscriptions","organizations_url":"https://api.github.com/users/yomigeek/orgs","repos_url":"https://api.github.com/users/yomigeek/repos","events_url":"https://api.github.com/users/yomigeek/events{/privacy}","received_events_url":"https://api.github.com/users/yomigeek/received_events","type":"User","site_admin":false},"body":"#### What does this PR do?\r\nuser should be able to reset their password\r\nsend reset link to user email on request\r\nverify reset mail token\r\nsend confirmation mail on password reset update\r\n\r\n#### Description of Task to be completed?\r\nadd sendMail helper method to send emails with sendGrid API\r\nadd sendResetEmail, verifyPasswordResetToken, and updateUserPassword methods in Password reset controller add an emailMessages helper method to store all email templates write unit tests to test the functionalities.\r\n\r\n#### How should this be manually tested?\r\nupon password reset request, an email containing link to the reset password will be sent to the user email address , when clicked, the token generated is been verified. After which the user are redirected to link containing a token for them to reset their password.\r\n\r\n#### Any background context you want to provide?\r\nN/A\r\n\r\n#### What are the relevant pivotal tracker stories?\r\nhttps://www.pivotaltracker.com/story/show/159204718\r\n\r\n","created_at":"2018-08-03T18:34:43Z","updated_at":"2018-08-03T18:35:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/andela/elven-ah/pulls/13/commits","review_comments_url":"https://api.github.com/repos/andela/elven-ah/pulls/13/comments","review_comment_url":"https://api.github.com/repos/andela/elven-ah/pulls/comments{/number}","comments_url":"https://api.github.com/repos/andela/elven-ah/issues/13/comments","statuses_url":"https://api.github.com/repos/andela/elven-ah/statuses/10b3aef20add18b52ea0c39e0970dd7921894536","head":{"label":"andela:feature/159204718/user-reset-password","ref":"feature/159204718/user-reset-password","sha":"10b3aef20add18b52ea0c39e0970dd7921894536","user":{"login":"andela","id":4100206,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQxMDAyMDY=","avatar_url":"https://avatars2.githubusercontent.com/u/4100206?v=4","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":141551482,"node_id":"MDEwOlJlcG9zaXRvcnkxNDE1NTE0ODI=","name":"elven-ah","full_name":"andela/elven-ah","owner":{"login":"andela","id":4100206,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQxMDAyMDY=","avatar_url":"https://avatars2.githubusercontent.com/u/4100206?v=4","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/elven-ah","description":null,"fork":false,"url":"https://api.github.com/repos/andela/elven-ah","forks_url":"https://api.github.com/repos/andela/elven-ah/forks","keys_url":"https://api.github.com/repos/andela/elven-ah/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/elven-ah/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/elven-ah/teams","hooks_url":"https://api.github.com/repos/andela/elven-ah/hooks","issue_events_url":"https://api.github.com/repos/andela/elven-ah/issues/events{/number}","events_url":"https://api.github.com/repos/andela/elven-ah/events","assignees_url":"https://api.github.com/repos/andela/elven-ah/assignees{/user}","branches_url":"https://api.github.com/repos/andela/elven-ah/branches{/branch}","tags_url":"https://api.github.com/repos/andela/elven-ah/tags","blobs_url":"https://api.github.com/repos/andela/elven-ah/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/elven-ah/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/elven-ah/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/elven-ah/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/elven-ah/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/elven-ah/languages","stargazers_url":"https://api.github.com/repos/andela/elven-ah/stargazers","contributors_url":"https://api.github.com/repos/andela/elven-ah/contributors","subscribers_url":"https://api.github.com/repos/andela/elven-ah/subscribers","subscription_url":"https://api.github.com/repos/andela/elven-ah/subscription","commits_url":"https://api.github.com/repos/andela/elven-ah/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/elven-ah/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/elven-ah/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/elven-ah/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/elven-ah/contents/{+path}","compare_url":"https://api.github.com/repos/andela/elven-ah/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/elven-ah/merges","archive_url":"https://api.github.com/repos/andela/elven-ah/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/elven-ah/downloads","issues_url":"https://api.github.com/repos/andela/elven-ah/issues{/number}","pulls_url":"https://api.github.com/repos/andela/elven-ah/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/elven-ah/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/elven-ah/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/elven-ah/labels{/name}","releases_url":"https://api.github.com/repos/andela/elven-ah/releases{/id}","deployments_url":"https://api.github.com/repos/andela/elven-ah/deployments","created_at":"2018-07-19T08:52:52Z","updated_at":"2018-08-03T18:13:24Z","pushed_at":"2018-08-03T18:34:44Z","git_url":"git://github.com/andela/elven-ah.git","ssh_url":"git@github.com:andela/elven-ah.git","clone_url":"https://github.com/andela/elven-ah.git","svn_url":"https://github.com/andela/elven-ah","homepage":null,"size":147,"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":"develop"}},"base":{"label":"andela:develop","ref":"develop","sha":"5c9173979b708020a5ca092b0a42093bba23a941","user":{"login":"andela","id":4100206,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQxMDAyMDY=","avatar_url":"https://avatars2.githubusercontent.com/u/4100206?v=4","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":141551482,"node_id":"MDEwOlJlcG9zaXRvcnkxNDE1NTE0ODI=","name":"elven-ah","full_name":"andela/elven-ah","owner":{"login":"andela","id":4100206,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQxMDAyMDY=","avatar_url":"https://avatars2.githubusercontent.com/u/4100206?v=4","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/elven-ah","description":null,"fork":false,"url":"https://api.github.com/repos/andela/elven-ah","forks_url":"https://api.github.com/repos/andela/elven-ah/forks","keys_url":"https://api.github.com/repos/andela/elven-ah/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/elven-ah/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/elven-ah/teams","hooks_url":"https://api.github.com/repos/andela/elven-ah/hooks","issue_events_url":"https://api.github.com/repos/andela/elven-ah/issues/events{/number}","events_url":"https://api.github.com/repos/andela/elven-ah/events","assignees_url":"https://api.github.com/repos/andela/elven-ah/assignees{/user}","branches_url":"https://api.github.com/repos/andela/elven-ah/branches{/branch}","tags_url":"https://api.github.com/repos/andela/elven-ah/tags","blobs_url":"https://api.github.com/repos/andela/elven-ah/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/elven-ah/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/elven-ah/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/elven-ah/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/elven-ah/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/elven-ah/languages","stargazers_url":"https://api.github.com/repos/andela/elven-ah/stargazers","contributors_url":"https://api.github.com/repos/andela/elven-ah/contributors","subscribers_url":"https://api.github.com/repos/andela/elven-ah/subscribers","subscription_url":"https://api.github.com/repos/andela/elven-ah/subscription","commits_url":"https://api.github.com/repos/andela/elven-ah/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/elven-ah/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/elven-ah/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/elven-ah/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/elven-ah/contents/{+path}","compare_url":"https://api.github.com/repos/andela/elven-ah/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/elven-ah/merges","archive_url":"https://api.github.com/repos/andela/elven-ah/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/elven-ah/downloads","issues_url":"https://api.github.com/repos/andela/elven-ah/issues{/number}","pulls_url":"https://api.github.com/repos/andela/elven-ah/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/elven-ah/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/elven-ah/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/elven-ah/labels{/name}","releases_url":"https://api.github.com/repos/andela/elven-ah/releases{/id}","deployments_url":"https://api.github.com/repos/andela/elven-ah/deployments","created_at":"2018-07-19T08:52:52Z","updated_at":"2018-08-03T18:13:24Z","pushed_at":"2018-08-03T18:34:44Z","git_url":"git://github.com/andela/elven-ah.git","ssh_url":"git@github.com:andela/elven-ah.git","clone_url":"https://github.com/andela/elven-ah.git","svn_url":"https://github.com/andela/elven-ah","homepage":null,"size":147,"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":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/13"},"html":{"href":"https://github.com/andela/elven-ah/pull/13"},"issue":{"href":"https://api.github.com/repos/andela/elven-ah/issues/13"},"comments":{"href":"https://api.github.com/repos/andela/elven-ah/issues/13/comments"},"review_comments":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/13/comments"},"review_comment":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/andela/elven-ah/pulls/13/commits"},"statuses":{"href":"https://api.github.com/repos/andela/elven-ah/statuses/10b3aef20add18b52ea0c39e0970dd7921894536"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"houndci-bot"}}