{"action":"created","comment":{"url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/comments/131611318","pull_request_review_id":54606778,"id":131611318,"diff_hunk":"@@ -0,0 +1,47 @@\n+class RelationshipsController < ApplicationController\n+  before_action :logged_in_user\n+  before_action :find_user, only: :index\n+  before_action :find_active_relationship, except: :index\n+  attr_reader :user\n+\n+  def index\n+    unless user\n+      flash[:danger] = t \"not_found\"\n+      redirect_to root_path\n+    end\n+    type = params[:type]\n+    @users = user.send(type).paginate page: params[:page]\n+    @title = type.to_s","path":"app/controllers/relationships_controller.rb","position":15,"original_position":14,"commit_id":"2ebcbdb65d179eb797d0a0690de9e83acb6c411c","original_commit_id":"7812bed7faa40e77d2276e4ab9bae95a9e73d888","user":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"body":"nhưng ở đây t có viết kiểu @title = \"following\" đâu mà cần i18n vậy ông ?","created_at":"2017-08-07T09:32:30Z","updated_at":"2017-08-07T09:32:30Z","html_url":"https://github.com/tung3457/sample-app-rails/pull/19#discussion_r131611318","pull_request_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19","_links":{"self":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/comments/131611318"},"html":{"href":"https://github.com/tung3457/sample-app-rails/pull/19#discussion_r131611318"},"pull_request":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19"}}},"pull_request":{"url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19","id":134379708,"html_url":"https://github.com/tung3457/sample-app-rails/pull/19","diff_url":"https://github.com/tung3457/sample-app-rails/pull/19.diff","patch_url":"https://github.com/tung3457/sample-app-rails/pull/19.patch","issue_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/19","number":19,"state":"open","locked":false,"title":"add user following","user":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"body":"![screen shot 2017-08-07 at 4 51 26 am](https://user-images.githubusercontent.com/19206277/29017058-5cf32cd6-7b7f-11e7-8cd6-13d6ae2028c8.png)\r\n","created_at":"2017-08-07T07:47:49Z","updated_at":"2017-08-07T09:32:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ebde59cc0b73d4797246f0c5eb91d1b170b1b920","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19/commits","review_comments_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19/comments","review_comment_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/19/comments","statuses_url":"https://api.github.com/repos/tung3457/sample-app-rails/statuses/2ebcbdb65d179eb797d0a0690de9e83acb6c411c","head":{"label":"tung3457:chap14-following-users","ref":"chap14-following-users","sha":"2ebcbdb65d179eb797d0a0690de9e83acb6c411c","user":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"repo":{"id":96871498,"name":"sample-app-rails","full_name":"tung3457/sample-app-rails","owner":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tung3457/sample-app-rails","description":null,"fork":false,"url":"https://api.github.com/repos/tung3457/sample-app-rails","forks_url":"https://api.github.com/repos/tung3457/sample-app-rails/forks","keys_url":"https://api.github.com/repos/tung3457/sample-app-rails/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tung3457/sample-app-rails/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tung3457/sample-app-rails/teams","hooks_url":"https://api.github.com/repos/tung3457/sample-app-rails/hooks","issue_events_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/events{/number}","events_url":"https://api.github.com/repos/tung3457/sample-app-rails/events","assignees_url":"https://api.github.com/repos/tung3457/sample-app-rails/assignees{/user}","branches_url":"https://api.github.com/repos/tung3457/sample-app-rails/branches{/branch}","tags_url":"https://api.github.com/repos/tung3457/sample-app-rails/tags","blobs_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/refs{/sha}","trees_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tung3457/sample-app-rails/statuses/{sha}","languages_url":"https://api.github.com/repos/tung3457/sample-app-rails/languages","stargazers_url":"https://api.github.com/repos/tung3457/sample-app-rails/stargazers","contributors_url":"https://api.github.com/repos/tung3457/sample-app-rails/contributors","subscribers_url":"https://api.github.com/repos/tung3457/sample-app-rails/subscribers","subscription_url":"https://api.github.com/repos/tung3457/sample-app-rails/subscription","commits_url":"https://api.github.com/repos/tung3457/sample-app-rails/commits{/sha}","git_commits_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/commits{/sha}","comments_url":"https://api.github.com/repos/tung3457/sample-app-rails/comments{/number}","issue_comment_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/comments{/number}","contents_url":"https://api.github.com/repos/tung3457/sample-app-rails/contents/{+path}","compare_url":"https://api.github.com/repos/tung3457/sample-app-rails/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tung3457/sample-app-rails/merges","archive_url":"https://api.github.com/repos/tung3457/sample-app-rails/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tung3457/sample-app-rails/downloads","issues_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues{/number}","pulls_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls{/number}","milestones_url":"https://api.github.com/repos/tung3457/sample-app-rails/milestones{/number}","notifications_url":"https://api.github.com/repos/tung3457/sample-app-rails/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tung3457/sample-app-rails/labels{/name}","releases_url":"https://api.github.com/repos/tung3457/sample-app-rails/releases{/id}","deployments_url":"https://api.github.com/repos/tung3457/sample-app-rails/deployments","created_at":"2017-07-11T08:44:07Z","updated_at":"2017-07-11T08:44:07Z","pushed_at":"2017-08-07T09:17:09Z","git_url":"git://github.com/tung3457/sample-app-rails.git","ssh_url":"git@github.com:tung3457/sample-app-rails.git","clone_url":"https://github.com/tung3457/sample-app-rails.git","svn_url":"https://github.com/tung3457/sample-app-rails","homepage":null,"size":121,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"tung3457:develop","ref":"develop","sha":"131b97f6f1f559b3cb8d863acf677b72d0b38acc","user":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"repo":{"id":96871498,"name":"sample-app-rails","full_name":"tung3457/sample-app-rails","owner":{"login":"tung3457","id":19206277,"avatar_url":"https://avatars1.githubusercontent.com/u/19206277?v=4","gravatar_id":"","url":"https://api.github.com/users/tung3457","html_url":"https://github.com/tung3457","followers_url":"https://api.github.com/users/tung3457/followers","following_url":"https://api.github.com/users/tung3457/following{/other_user}","gists_url":"https://api.github.com/users/tung3457/gists{/gist_id}","starred_url":"https://api.github.com/users/tung3457/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tung3457/subscriptions","organizations_url":"https://api.github.com/users/tung3457/orgs","repos_url":"https://api.github.com/users/tung3457/repos","events_url":"https://api.github.com/users/tung3457/events{/privacy}","received_events_url":"https://api.github.com/users/tung3457/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tung3457/sample-app-rails","description":null,"fork":false,"url":"https://api.github.com/repos/tung3457/sample-app-rails","forks_url":"https://api.github.com/repos/tung3457/sample-app-rails/forks","keys_url":"https://api.github.com/repos/tung3457/sample-app-rails/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tung3457/sample-app-rails/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tung3457/sample-app-rails/teams","hooks_url":"https://api.github.com/repos/tung3457/sample-app-rails/hooks","issue_events_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/events{/number}","events_url":"https://api.github.com/repos/tung3457/sample-app-rails/events","assignees_url":"https://api.github.com/repos/tung3457/sample-app-rails/assignees{/user}","branches_url":"https://api.github.com/repos/tung3457/sample-app-rails/branches{/branch}","tags_url":"https://api.github.com/repos/tung3457/sample-app-rails/tags","blobs_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/refs{/sha}","trees_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tung3457/sample-app-rails/statuses/{sha}","languages_url":"https://api.github.com/repos/tung3457/sample-app-rails/languages","stargazers_url":"https://api.github.com/repos/tung3457/sample-app-rails/stargazers","contributors_url":"https://api.github.com/repos/tung3457/sample-app-rails/contributors","subscribers_url":"https://api.github.com/repos/tung3457/sample-app-rails/subscribers","subscription_url":"https://api.github.com/repos/tung3457/sample-app-rails/subscription","commits_url":"https://api.github.com/repos/tung3457/sample-app-rails/commits{/sha}","git_commits_url":"https://api.github.com/repos/tung3457/sample-app-rails/git/commits{/sha}","comments_url":"https://api.github.com/repos/tung3457/sample-app-rails/comments{/number}","issue_comment_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues/comments{/number}","contents_url":"https://api.github.com/repos/tung3457/sample-app-rails/contents/{+path}","compare_url":"https://api.github.com/repos/tung3457/sample-app-rails/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tung3457/sample-app-rails/merges","archive_url":"https://api.github.com/repos/tung3457/sample-app-rails/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tung3457/sample-app-rails/downloads","issues_url":"https://api.github.com/repos/tung3457/sample-app-rails/issues{/number}","pulls_url":"https://api.github.com/repos/tung3457/sample-app-rails/pulls{/number}","milestones_url":"https://api.github.com/repos/tung3457/sample-app-rails/milestones{/number}","notifications_url":"https://api.github.com/repos/tung3457/sample-app-rails/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tung3457/sample-app-rails/labels{/name}","releases_url":"https://api.github.com/repos/tung3457/sample-app-rails/releases{/id}","deployments_url":"https://api.github.com/repos/tung3457/sample-app-rails/deployments","created_at":"2017-07-11T08:44:07Z","updated_at":"2017-07-11T08:44:07Z","pushed_at":"2017-08-07T09:17:09Z","git_url":"git://github.com/tung3457/sample-app-rails.git","ssh_url":"git@github.com:tung3457/sample-app-rails.git","clone_url":"https://github.com/tung3457/sample-app-rails.git","svn_url":"https://github.com/tung3457/sample-app-rails","homepage":null,"size":121,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19"},"html":{"href":"https://github.com/tung3457/sample-app-rails/pull/19"},"issue":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/issues/19"},"comments":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/issues/19/comments"},"review_comments":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19/comments"},"review_comment":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/pulls/19/commits"},"statuses":{"href":"https://api.github.com/repos/tung3457/sample-app-rails/statuses/2ebcbdb65d179eb797d0a0690de9e83acb6c411c"}}}}
{"actor":{"display_login":"tung3457"}}