{"action":"created","comment":{"url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/comments/222245332","pull_request_review_id":161082549,"id":222245332,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMjI0NTMzMg==","diff_hunk":"@@ -18,14 +20,56 @@ def create\n       flash[:success] = t \".welcome\"\n       redirect_to @user\n     else \n-      flash[:danger] = t \".failed\" \n+      flash[:danger] = t \".failed\"\n       render :new \n     end\n   end\n \n+  def edit; end\n+\n+  def update\n+    if @user.update_attributes user_params\n+      flash[:success] = t \".updated_success\"\n+      redirect_to @user\n+    else \n+      render :edit\n+    end\n+  end\n+\n+  def destroy\n+    @user.destroy\n+    flash[:success] = t \".user_deleted\"\n+    redirect_to users_url\n+  end\n+\n   private\n \n+  def load_user \n+    @user = User.find_by id:params[:id]\n+    return if @user\n+      flash[:danger] = t \".user_not_found\"","path":"app/controllers/users_controller.rb","position":55,"original_position":55,"commit_id":"2faaf03237557d401c7df741af39aeee18021815","original_commit_id":"2faaf03237557d401c7df741af39aeee18021815","user":{"login":"huuphuc93","id":32001464,"node_id":"MDQ6VXNlcjMyMDAxNDY0","avatar_url":"https://avatars1.githubusercontent.com/u/32001464?v=4","gravatar_id":"","url":"https://api.github.com/users/huuphuc93","html_url":"https://github.com/huuphuc93","followers_url":"https://api.github.com/users/huuphuc93/followers","following_url":"https://api.github.com/users/huuphuc93/following{/other_user}","gists_url":"https://api.github.com/users/huuphuc93/gists{/gist_id}","starred_url":"https://api.github.com/users/huuphuc93/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huuphuc93/subscriptions","organizations_url":"https://api.github.com/users/huuphuc93/orgs","repos_url":"https://api.github.com/users/huuphuc93/repos","events_url":"https://api.github.com/users/huuphuc93/events{/privacy}","received_events_url":"https://api.github.com/users/huuphuc93/received_events","type":"User","site_admin":false},"body":"lùi ra đầu dòng 2 spaces","created_at":"2018-10-03T09:38:45Z","updated_at":"2018-10-03T09:38:45Z","html_url":"https://github.com/duongthao1610/sample_app_2/pull/7#discussion_r222245332","pull_request_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/comments/222245332"},"html":{"href":"https://github.com/duongthao1610/sample_app_2/pull/7#discussion_r222245332"},"pull_request":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7","id":219931848,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE5OTMxODQ4","html_url":"https://github.com/duongthao1610/sample_app_2/pull/7","diff_url":"https://github.com/duongthao1610/sample_app_2/pull/7.diff","patch_url":"https://github.com/duongthao1610/sample_app_2/pull/7.patch","issue_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/7","number":7,"state":"open","locked":false,"title":"Updating users","user":{"login":"duongthao1610","id":32006537,"node_id":"MDQ6VXNlcjMyMDA2NTM3","avatar_url":"https://avatars3.githubusercontent.com/u/32006537?v=4","gravatar_id":"","url":"https://api.github.com/users/duongthao1610","html_url":"https://github.com/duongthao1610","followers_url":"https://api.github.com/users/duongthao1610/followers","following_url":"https://api.github.com/users/duongthao1610/following{/other_user}","gists_url":"https://api.github.com/users/duongthao1610/gists{/gist_id}","starred_url":"https://api.github.com/users/duongthao1610/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duongthao1610/subscriptions","organizations_url":"https://api.github.com/users/duongthao1610/orgs","repos_url":"https://api.github.com/users/duongthao1610/repos","events_url":"https://api.github.com/users/duongthao1610/events{/privacy}","received_events_url":"https://api.github.com/users/duongthao1610/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-10-03T06:52:48Z","updated_at":"2018-10-03T09:38:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"64cabdb3348532316914a40a47ebcf43955f7645","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7/commits","review_comments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7/comments","review_comment_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/7/comments","statuses_url":"https://api.github.com/repos/duongthao1610/sample_app_2/statuses/2faaf03237557d401c7df741af39aeee18021815","head":{"label":"duongthao1610:updating-users","ref":"updating-users","sha":"2faaf03237557d401c7df741af39aeee18021815","user":{"login":"duongthao1610","id":32006537,"node_id":"MDQ6VXNlcjMyMDA2NTM3","avatar_url":"https://avatars3.githubusercontent.com/u/32006537?v=4","gravatar_id":"","url":"https://api.github.com/users/duongthao1610","html_url":"https://github.com/duongthao1610","followers_url":"https://api.github.com/users/duongthao1610/followers","following_url":"https://api.github.com/users/duongthao1610/following{/other_user}","gists_url":"https://api.github.com/users/duongthao1610/gists{/gist_id}","starred_url":"https://api.github.com/users/duongthao1610/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duongthao1610/subscriptions","organizations_url":"https://api.github.com/users/duongthao1610/orgs","repos_url":"https://api.github.com/users/duongthao1610/repos","events_url":"https://api.github.com/users/duongthao1610/events{/privacy}","received_events_url":"https://api.github.com/users/duongthao1610/received_events","type":"User","site_admin":false},"repo":{"id":150358859,"node_id":"MDEwOlJlcG9zaXRvcnkxNTAzNTg4NTk=","name":"sample_app_2","full_name":"duongthao1610/sample_app_2","private":false,"owner":{"login":"duongthao1610","id":32006537,"node_id":"MDQ6VXNlcjMyMDA2NTM3","avatar_url":"https://avatars3.githubusercontent.com/u/32006537?v=4","gravatar_id":"","url":"https://api.github.com/users/duongthao1610","html_url":"https://github.com/duongthao1610","followers_url":"https://api.github.com/users/duongthao1610/followers","following_url":"https://api.github.com/users/duongthao1610/following{/other_user}","gists_url":"https://api.github.com/users/duongthao1610/gists{/gist_id}","starred_url":"https://api.github.com/users/duongthao1610/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duongthao1610/subscriptions","organizations_url":"https://api.github.com/users/duongthao1610/orgs","repos_url":"https://api.github.com/users/duongthao1610/repos","events_url":"https://api.github.com/users/duongthao1610/events{/privacy}","received_events_url":"https://api.github.com/users/duongthao1610/received_events","type":"User","site_admin":false},"html_url":"https://github.com/duongthao1610/sample_app_2","description":"Sample_app Fr","fork":false,"url":"https://api.github.com/repos/duongthao1610/sample_app_2","forks_url":"https://api.github.com/repos/duongthao1610/sample_app_2/forks","keys_url":"https://api.github.com/repos/duongthao1610/sample_app_2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/duongthao1610/sample_app_2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/duongthao1610/sample_app_2/teams","hooks_url":"https://api.github.com/repos/duongthao1610/sample_app_2/hooks","issue_events_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/events{/number}","events_url":"https://api.github.com/repos/duongthao1610/sample_app_2/events","assignees_url":"https://api.github.com/repos/duongthao1610/sample_app_2/assignees{/user}","branches_url":"https://api.github.com/repos/duongthao1610/sample_app_2/branches{/branch}","tags_url":"https://api.github.com/repos/duongthao1610/sample_app_2/tags","blobs_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/refs{/sha}","trees_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/duongthao1610/sample_app_2/statuses/{sha}","languages_url":"https://api.github.com/repos/duongthao1610/sample_app_2/languages","stargazers_url":"https://api.github.com/repos/duongthao1610/sample_app_2/stargazers","contributors_url":"https://api.github.com/repos/duongthao1610/sample_app_2/contributors","subscribers_url":"https://api.github.com/repos/duongthao1610/sample_app_2/subscribers","subscription_url":"https://api.github.com/repos/duongthao1610/sample_app_2/subscription","commits_url":"https://api.github.com/repos/duongthao1610/sample_app_2/commits{/sha}","git_commits_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/commits{/sha}","comments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/comments{/number}","issue_comment_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/comments{/number}","contents_url":"https://api.github.com/repos/duongthao1610/sample_app_2/contents/{+path}","compare_url":"https://api.github.com/repos/duongthao1610/sample_app_2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/duongthao1610/sample_app_2/merges","archive_url":"https://api.github.com/repos/duongthao1610/sample_app_2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/duongthao1610/sample_app_2/downloads","issues_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues{/number}","pulls_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls{/number}","milestones_url":"https://api.github.com/repos/duongthao1610/sample_app_2/milestones{/number}","notifications_url":"https://api.github.com/repos/duongthao1610/sample_app_2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/duongthao1610/sample_app_2/labels{/name}","releases_url":"https://api.github.com/repos/duongthao1610/sample_app_2/releases{/id}","deployments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/deployments","created_at":"2018-09-26T02:43:41Z","updated_at":"2018-10-03T06:18:35Z","pushed_at":"2018-10-03T09:35:49Z","git_url":"git://github.com/duongthao1610/sample_app_2.git","ssh_url":"git@github.com:duongthao1610/sample_app_2.git","clone_url":"https://github.com/duongthao1610/sample_app_2.git","svn_url":"https://github.com/duongthao1610/sample_app_2","homepage":null,"size":213,"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":"duongthao1610:master","ref":"master","sha":"2043dfd11ac7e3cdbe2d31ccb18dd4592ebcb582","user":{"login":"duongthao1610","id":32006537,"node_id":"MDQ6VXNlcjMyMDA2NTM3","avatar_url":"https://avatars3.githubusercontent.com/u/32006537?v=4","gravatar_id":"","url":"https://api.github.com/users/duongthao1610","html_url":"https://github.com/duongthao1610","followers_url":"https://api.github.com/users/duongthao1610/followers","following_url":"https://api.github.com/users/duongthao1610/following{/other_user}","gists_url":"https://api.github.com/users/duongthao1610/gists{/gist_id}","starred_url":"https://api.github.com/users/duongthao1610/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duongthao1610/subscriptions","organizations_url":"https://api.github.com/users/duongthao1610/orgs","repos_url":"https://api.github.com/users/duongthao1610/repos","events_url":"https://api.github.com/users/duongthao1610/events{/privacy}","received_events_url":"https://api.github.com/users/duongthao1610/received_events","type":"User","site_admin":false},"repo":{"id":150358859,"node_id":"MDEwOlJlcG9zaXRvcnkxNTAzNTg4NTk=","name":"sample_app_2","full_name":"duongthao1610/sample_app_2","private":false,"owner":{"login":"duongthao1610","id":32006537,"node_id":"MDQ6VXNlcjMyMDA2NTM3","avatar_url":"https://avatars3.githubusercontent.com/u/32006537?v=4","gravatar_id":"","url":"https://api.github.com/users/duongthao1610","html_url":"https://github.com/duongthao1610","followers_url":"https://api.github.com/users/duongthao1610/followers","following_url":"https://api.github.com/users/duongthao1610/following{/other_user}","gists_url":"https://api.github.com/users/duongthao1610/gists{/gist_id}","starred_url":"https://api.github.com/users/duongthao1610/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duongthao1610/subscriptions","organizations_url":"https://api.github.com/users/duongthao1610/orgs","repos_url":"https://api.github.com/users/duongthao1610/repos","events_url":"https://api.github.com/users/duongthao1610/events{/privacy}","received_events_url":"https://api.github.com/users/duongthao1610/received_events","type":"User","site_admin":false},"html_url":"https://github.com/duongthao1610/sample_app_2","description":"Sample_app Fr","fork":false,"url":"https://api.github.com/repos/duongthao1610/sample_app_2","forks_url":"https://api.github.com/repos/duongthao1610/sample_app_2/forks","keys_url":"https://api.github.com/repos/duongthao1610/sample_app_2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/duongthao1610/sample_app_2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/duongthao1610/sample_app_2/teams","hooks_url":"https://api.github.com/repos/duongthao1610/sample_app_2/hooks","issue_events_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/events{/number}","events_url":"https://api.github.com/repos/duongthao1610/sample_app_2/events","assignees_url":"https://api.github.com/repos/duongthao1610/sample_app_2/assignees{/user}","branches_url":"https://api.github.com/repos/duongthao1610/sample_app_2/branches{/branch}","tags_url":"https://api.github.com/repos/duongthao1610/sample_app_2/tags","blobs_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/refs{/sha}","trees_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/duongthao1610/sample_app_2/statuses/{sha}","languages_url":"https://api.github.com/repos/duongthao1610/sample_app_2/languages","stargazers_url":"https://api.github.com/repos/duongthao1610/sample_app_2/stargazers","contributors_url":"https://api.github.com/repos/duongthao1610/sample_app_2/contributors","subscribers_url":"https://api.github.com/repos/duongthao1610/sample_app_2/subscribers","subscription_url":"https://api.github.com/repos/duongthao1610/sample_app_2/subscription","commits_url":"https://api.github.com/repos/duongthao1610/sample_app_2/commits{/sha}","git_commits_url":"https://api.github.com/repos/duongthao1610/sample_app_2/git/commits{/sha}","comments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/comments{/number}","issue_comment_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/comments{/number}","contents_url":"https://api.github.com/repos/duongthao1610/sample_app_2/contents/{+path}","compare_url":"https://api.github.com/repos/duongthao1610/sample_app_2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/duongthao1610/sample_app_2/merges","archive_url":"https://api.github.com/repos/duongthao1610/sample_app_2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/duongthao1610/sample_app_2/downloads","issues_url":"https://api.github.com/repos/duongthao1610/sample_app_2/issues{/number}","pulls_url":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls{/number}","milestones_url":"https://api.github.com/repos/duongthao1610/sample_app_2/milestones{/number}","notifications_url":"https://api.github.com/repos/duongthao1610/sample_app_2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/duongthao1610/sample_app_2/labels{/name}","releases_url":"https://api.github.com/repos/duongthao1610/sample_app_2/releases{/id}","deployments_url":"https://api.github.com/repos/duongthao1610/sample_app_2/deployments","created_at":"2018-09-26T02:43:41Z","updated_at":"2018-10-03T06:18:35Z","pushed_at":"2018-10-03T09:35:49Z","git_url":"git://github.com/duongthao1610/sample_app_2.git","ssh_url":"git@github.com:duongthao1610/sample_app_2.git","clone_url":"https://github.com/duongthao1610/sample_app_2.git","svn_url":"https://github.com/duongthao1610/sample_app_2","homepage":null,"size":213,"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/duongthao1610/sample_app_2/pulls/7"},"html":{"href":"https://github.com/duongthao1610/sample_app_2/pull/7"},"issue":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/7"},"comments":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/duongthao1610/sample_app_2/statuses/2faaf03237557d401c7df741af39aeee18021815"}},"author_association":"OWNER"}}
{"actor":{"display_login":"huuphuc93"}}