{"action":"created","comment":{"url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/comments/202282687","pull_request_review_id":136951616,"id":202282687,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwMjI4MjY4Nw==","diff_hunk":"@@ -12,10 +13,31 @@ class User < ApplicationRecord\n \n   has_secure_password\n \n-  def User.digest string\n-    cost = ActiveModel::SecurePassword.min_cost ? BCrypt::Engine::MIN_COST :\n-                                                  BCrypt::Engine.cost\n-    BCrypt::Password.create string, cost: cost\n+  def remember\n+    self.remember_token = User.new_token\n+    update_attribute(:remember_digest, User.digest(remember_token))\n+  end\n+\n+  def authenticated? remember_token\n+    return false if remember_digest.nil?\n+    BCrypt::Password.new(remember_digest).is_password?(remember_token)","path":"app/models/user.rb","position":21,"original_position":21,"commit_id":"ee9fc1e592b6a8fba213a1a42808435f42cd0bd7","original_commit_id":"ee9fc1e592b6a8fba213a1a42808435f42cd0bd7","user":{"login":"thanhhungchu95","id":8967163,"node_id":"MDQ6VXNlcjg5NjcxNjM=","avatar_url":"https://avatars2.githubusercontent.com/u/8967163?v=4","gravatar_id":"","url":"https://api.github.com/users/thanhhungchu95","html_url":"https://github.com/thanhhungchu95","followers_url":"https://api.github.com/users/thanhhungchu95/followers","following_url":"https://api.github.com/users/thanhhungchu95/following{/other_user}","gists_url":"https://api.github.com/users/thanhhungchu95/gists{/gist_id}","starred_url":"https://api.github.com/users/thanhhungchu95/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thanhhungchu95/subscriptions","organizations_url":"https://api.github.com/users/thanhhungchu95/orgs","repos_url":"https://api.github.com/users/thanhhungchu95/repos","events_url":"https://api.github.com/users/thanhhungchu95/events{/privacy}","received_events_url":"https://api.github.com/users/thanhhungchu95/received_events","type":"User","site_admin":false},"body":"bỏ () ở is_password?","created_at":"2018-07-13T08:42:33Z","updated_at":"2018-07-13T08:43:02Z","html_url":"https://github.com/NinhThiLien/sample_app/pull/10#discussion_r202282687","pull_request_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/comments/202282687"},"html":{"href":"https://github.com/NinhThiLien/sample_app/pull/10#discussion_r202282687"},"pull_request":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10"}}},"pull_request":{"url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10","id":201217245,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAxMjE3MjQ1","html_url":"https://github.com/NinhThiLien/sample_app/pull/10","diff_url":"https://github.com/NinhThiLien/sample_app/pull/10.diff","patch_url":"https://github.com/NinhThiLien/sample_app/pull/10.patch","issue_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/10","number":10,"state":"open","locked":false,"title":"chapter9 - advanced-login","user":{"login":"NinhThiLien","id":26185253,"node_id":"MDQ6VXNlcjI2MTg1MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/26185253?v=4","gravatar_id":"","url":"https://api.github.com/users/NinhThiLien","html_url":"https://github.com/NinhThiLien","followers_url":"https://api.github.com/users/NinhThiLien/followers","following_url":"https://api.github.com/users/NinhThiLien/following{/other_user}","gists_url":"https://api.github.com/users/NinhThiLien/gists{/gist_id}","starred_url":"https://api.github.com/users/NinhThiLien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NinhThiLien/subscriptions","organizations_url":"https://api.github.com/users/NinhThiLien/orgs","repos_url":"https://api.github.com/users/NinhThiLien/repos","events_url":"https://api.github.com/users/NinhThiLien/events{/privacy}","received_events_url":"https://api.github.com/users/NinhThiLien/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-07-13T08:09:50Z","updated_at":"2018-07-13T08:43:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f0fd598bbdf57f0a1d5b511dde0b4e417007fde7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10/commits","review_comments_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10/comments","review_comment_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/comments{/number}","comments_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/10/comments","statuses_url":"https://api.github.com/repos/NinhThiLien/sample_app/statuses/ee9fc1e592b6a8fba213a1a42808435f42cd0bd7","head":{"label":"NinhThiLien:advanced-login","ref":"advanced-login","sha":"ee9fc1e592b6a8fba213a1a42808435f42cd0bd7","user":{"login":"NinhThiLien","id":26185253,"node_id":"MDQ6VXNlcjI2MTg1MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/26185253?v=4","gravatar_id":"","url":"https://api.github.com/users/NinhThiLien","html_url":"https://github.com/NinhThiLien","followers_url":"https://api.github.com/users/NinhThiLien/followers","following_url":"https://api.github.com/users/NinhThiLien/following{/other_user}","gists_url":"https://api.github.com/users/NinhThiLien/gists{/gist_id}","starred_url":"https://api.github.com/users/NinhThiLien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NinhThiLien/subscriptions","organizations_url":"https://api.github.com/users/NinhThiLien/orgs","repos_url":"https://api.github.com/users/NinhThiLien/repos","events_url":"https://api.github.com/users/NinhThiLien/events{/privacy}","received_events_url":"https://api.github.com/users/NinhThiLien/received_events","type":"User","site_admin":false},"repo":{"id":139938010,"node_id":"MDEwOlJlcG9zaXRvcnkxMzk5MzgwMTA=","name":"sample_app","full_name":"NinhThiLien/sample_app","owner":{"login":"NinhThiLien","id":26185253,"node_id":"MDQ6VXNlcjI2MTg1MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/26185253?v=4","gravatar_id":"","url":"https://api.github.com/users/NinhThiLien","html_url":"https://github.com/NinhThiLien","followers_url":"https://api.github.com/users/NinhThiLien/followers","following_url":"https://api.github.com/users/NinhThiLien/following{/other_user}","gists_url":"https://api.github.com/users/NinhThiLien/gists{/gist_id}","starred_url":"https://api.github.com/users/NinhThiLien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NinhThiLien/subscriptions","organizations_url":"https://api.github.com/users/NinhThiLien/orgs","repos_url":"https://api.github.com/users/NinhThiLien/repos","events_url":"https://api.github.com/users/NinhThiLien/events{/privacy}","received_events_url":"https://api.github.com/users/NinhThiLien/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/NinhThiLien/sample_app","description":null,"fork":false,"url":"https://api.github.com/repos/NinhThiLien/sample_app","forks_url":"https://api.github.com/repos/NinhThiLien/sample_app/forks","keys_url":"https://api.github.com/repos/NinhThiLien/sample_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NinhThiLien/sample_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NinhThiLien/sample_app/teams","hooks_url":"https://api.github.com/repos/NinhThiLien/sample_app/hooks","issue_events_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/events{/number}","events_url":"https://api.github.com/repos/NinhThiLien/sample_app/events","assignees_url":"https://api.github.com/repos/NinhThiLien/sample_app/assignees{/user}","branches_url":"https://api.github.com/repos/NinhThiLien/sample_app/branches{/branch}","tags_url":"https://api.github.com/repos/NinhThiLien/sample_app/tags","blobs_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NinhThiLien/sample_app/statuses/{sha}","languages_url":"https://api.github.com/repos/NinhThiLien/sample_app/languages","stargazers_url":"https://api.github.com/repos/NinhThiLien/sample_app/stargazers","contributors_url":"https://api.github.com/repos/NinhThiLien/sample_app/contributors","subscribers_url":"https://api.github.com/repos/NinhThiLien/sample_app/subscribers","subscription_url":"https://api.github.com/repos/NinhThiLien/sample_app/subscription","commits_url":"https://api.github.com/repos/NinhThiLien/sample_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/NinhThiLien/sample_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/NinhThiLien/sample_app/contents/{+path}","compare_url":"https://api.github.com/repos/NinhThiLien/sample_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NinhThiLien/sample_app/merges","archive_url":"https://api.github.com/repos/NinhThiLien/sample_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NinhThiLien/sample_app/downloads","issues_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues{/number}","pulls_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls{/number}","milestones_url":"https://api.github.com/repos/NinhThiLien/sample_app/milestones{/number}","notifications_url":"https://api.github.com/repos/NinhThiLien/sample_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NinhThiLien/sample_app/labels{/name}","releases_url":"https://api.github.com/repos/NinhThiLien/sample_app/releases{/id}","deployments_url":"https://api.github.com/repos/NinhThiLien/sample_app/deployments","created_at":"2018-07-06T05:39:08Z","updated_at":"2018-07-13T06:39:32Z","pushed_at":"2018-07-13T08:31:49Z","git_url":"git://github.com/NinhThiLien/sample_app.git","ssh_url":"git@github.com:NinhThiLien/sample_app.git","clone_url":"https://github.com/NinhThiLien/sample_app.git","svn_url":"https://github.com/NinhThiLien/sample_app","homepage":null,"size":72,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"NinhThiLien:master","ref":"master","sha":"1d0adc1b0b232446ae8d3233994f07488abdf681","user":{"login":"NinhThiLien","id":26185253,"node_id":"MDQ6VXNlcjI2MTg1MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/26185253?v=4","gravatar_id":"","url":"https://api.github.com/users/NinhThiLien","html_url":"https://github.com/NinhThiLien","followers_url":"https://api.github.com/users/NinhThiLien/followers","following_url":"https://api.github.com/users/NinhThiLien/following{/other_user}","gists_url":"https://api.github.com/users/NinhThiLien/gists{/gist_id}","starred_url":"https://api.github.com/users/NinhThiLien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NinhThiLien/subscriptions","organizations_url":"https://api.github.com/users/NinhThiLien/orgs","repos_url":"https://api.github.com/users/NinhThiLien/repos","events_url":"https://api.github.com/users/NinhThiLien/events{/privacy}","received_events_url":"https://api.github.com/users/NinhThiLien/received_events","type":"User","site_admin":false},"repo":{"id":139938010,"node_id":"MDEwOlJlcG9zaXRvcnkxMzk5MzgwMTA=","name":"sample_app","full_name":"NinhThiLien/sample_app","owner":{"login":"NinhThiLien","id":26185253,"node_id":"MDQ6VXNlcjI2MTg1MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/26185253?v=4","gravatar_id":"","url":"https://api.github.com/users/NinhThiLien","html_url":"https://github.com/NinhThiLien","followers_url":"https://api.github.com/users/NinhThiLien/followers","following_url":"https://api.github.com/users/NinhThiLien/following{/other_user}","gists_url":"https://api.github.com/users/NinhThiLien/gists{/gist_id}","starred_url":"https://api.github.com/users/NinhThiLien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NinhThiLien/subscriptions","organizations_url":"https://api.github.com/users/NinhThiLien/orgs","repos_url":"https://api.github.com/users/NinhThiLien/repos","events_url":"https://api.github.com/users/NinhThiLien/events{/privacy}","received_events_url":"https://api.github.com/users/NinhThiLien/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/NinhThiLien/sample_app","description":null,"fork":false,"url":"https://api.github.com/repos/NinhThiLien/sample_app","forks_url":"https://api.github.com/repos/NinhThiLien/sample_app/forks","keys_url":"https://api.github.com/repos/NinhThiLien/sample_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NinhThiLien/sample_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NinhThiLien/sample_app/teams","hooks_url":"https://api.github.com/repos/NinhThiLien/sample_app/hooks","issue_events_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/events{/number}","events_url":"https://api.github.com/repos/NinhThiLien/sample_app/events","assignees_url":"https://api.github.com/repos/NinhThiLien/sample_app/assignees{/user}","branches_url":"https://api.github.com/repos/NinhThiLien/sample_app/branches{/branch}","tags_url":"https://api.github.com/repos/NinhThiLien/sample_app/tags","blobs_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NinhThiLien/sample_app/statuses/{sha}","languages_url":"https://api.github.com/repos/NinhThiLien/sample_app/languages","stargazers_url":"https://api.github.com/repos/NinhThiLien/sample_app/stargazers","contributors_url":"https://api.github.com/repos/NinhThiLien/sample_app/contributors","subscribers_url":"https://api.github.com/repos/NinhThiLien/sample_app/subscribers","subscription_url":"https://api.github.com/repos/NinhThiLien/sample_app/subscription","commits_url":"https://api.github.com/repos/NinhThiLien/sample_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/NinhThiLien/sample_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/NinhThiLien/sample_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/NinhThiLien/sample_app/contents/{+path}","compare_url":"https://api.github.com/repos/NinhThiLien/sample_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NinhThiLien/sample_app/merges","archive_url":"https://api.github.com/repos/NinhThiLien/sample_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NinhThiLien/sample_app/downloads","issues_url":"https://api.github.com/repos/NinhThiLien/sample_app/issues{/number}","pulls_url":"https://api.github.com/repos/NinhThiLien/sample_app/pulls{/number}","milestones_url":"https://api.github.com/repos/NinhThiLien/sample_app/milestones{/number}","notifications_url":"https://api.github.com/repos/NinhThiLien/sample_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NinhThiLien/sample_app/labels{/name}","releases_url":"https://api.github.com/repos/NinhThiLien/sample_app/releases{/id}","deployments_url":"https://api.github.com/repos/NinhThiLien/sample_app/deployments","created_at":"2018-07-06T05:39:08Z","updated_at":"2018-07-13T06:39:32Z","pushed_at":"2018-07-13T08:31:49Z","git_url":"git://github.com/NinhThiLien/sample_app.git","ssh_url":"git@github.com:NinhThiLien/sample_app.git","clone_url":"https://github.com/NinhThiLien/sample_app.git","svn_url":"https://github.com/NinhThiLien/sample_app","homepage":null,"size":72,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10"},"html":{"href":"https://github.com/NinhThiLien/sample_app/pull/10"},"issue":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/issues/10"},"comments":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/issues/10/comments"},"review_comments":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10/comments"},"review_comment":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/pulls/10/commits"},"statuses":{"href":"https://api.github.com/repos/NinhThiLien/sample_app/statuses/ee9fc1e592b6a8fba213a1a42808435f42cd0bd7"}},"author_association":"OWNER"}}
{"actor":{"display_login":"thanhhungchu95"}}