{"action":"created","comment":{"url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/comments/49615693","id":49615693,"diff_hunk":"@@ -11,9 +11,27 @@ def authenticate_user\n     end\n   end\n \n-  def authorize_user\n-    if !user_signed_in? || !current_user.admin?\n+  def station_authorize_user\n+    station = Station.find(params[:id])\n+    if !user_signed_in?\n       raise ActionController::RoutingError.new(\"Not Found\")\n+      unless current_user.admin?","path":"app/controllers/application_controller.rb","position":10,"original_position":10,"commit_id":"47e2abe38a1645576e980b4036a962f3f0095a60","original_commit_id":"47e2abe38a1645576e980b4036a962f3f0095a60","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Unreachable code detected.","created_at":"2016-01-13T16:46:37Z","updated_at":"2016-01-13T16:46:37Z","html_url":"https://github.com/rdobrins/subway_review_site/pull/24#discussion_r49615693","pull_request_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24","_links":{"self":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/comments/49615693"},"html":{"href":"https://github.com/rdobrins/subway_review_site/pull/24#discussion_r49615693"},"pull_request":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24"}}},"pull_request":{"url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24","id":55923119,"html_url":"https://github.com/rdobrins/subway_review_site/pull/24","diff_url":"https://github.com/rdobrins/subway_review_site/pull/24.diff","patch_url":"https://github.com/rdobrins/subway_review_site/pull/24.patch","issue_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/24","number":24,"state":"open","locked":false,"title":"Edit and delete by creator","user":{"login":"vermartian","id":14897176,"avatar_url":"https://avatars.githubusercontent.com/u/14897176?v=3","gravatar_id":"","url":"https://api.github.com/users/vermartian","html_url":"https://github.com/vermartian","followers_url":"https://api.github.com/users/vermartian/followers","following_url":"https://api.github.com/users/vermartian/following{/other_user}","gists_url":"https://api.github.com/users/vermartian/gists{/gist_id}","starred_url":"https://api.github.com/users/vermartian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vermartian/subscriptions","organizations_url":"https://api.github.com/users/vermartian/orgs","repos_url":"https://api.github.com/users/vermartian/repos","events_url":"https://api.github.com/users/vermartian/events{/privacy}","received_events_url":"https://api.github.com/users/vermartian/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-01-13T16:46:30Z","updated_at":"2016-01-13T16:46:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a348c5c626ada98b478ee1a55998d86c0f9a091f","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24/commits","review_comments_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24/comments","review_comment_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/24/comments","statuses_url":"https://api.github.com/repos/rdobrins/subway_review_site/statuses/47e2abe38a1645576e980b4036a962f3f0095a60","head":{"label":"rdobrins:edit-and-delete-by-creator","ref":"edit-and-delete-by-creator","sha":"47e2abe38a1645576e980b4036a962f3f0095a60","user":{"login":"rdobrins","id":13757640,"avatar_url":"https://avatars.githubusercontent.com/u/13757640?v=3","gravatar_id":"","url":"https://api.github.com/users/rdobrins","html_url":"https://github.com/rdobrins","followers_url":"https://api.github.com/users/rdobrins/followers","following_url":"https://api.github.com/users/rdobrins/following{/other_user}","gists_url":"https://api.github.com/users/rdobrins/gists{/gist_id}","starred_url":"https://api.github.com/users/rdobrins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rdobrins/subscriptions","organizations_url":"https://api.github.com/users/rdobrins/orgs","repos_url":"https://api.github.com/users/rdobrins/repos","events_url":"https://api.github.com/users/rdobrins/events{/privacy}","received_events_url":"https://api.github.com/users/rdobrins/received_events","type":"User","site_admin":false},"repo":{"id":49006212,"name":"subway_review_site","full_name":"rdobrins/subway_review_site","owner":{"login":"rdobrins","id":13757640,"avatar_url":"https://avatars.githubusercontent.com/u/13757640?v=3","gravatar_id":"","url":"https://api.github.com/users/rdobrins","html_url":"https://github.com/rdobrins","followers_url":"https://api.github.com/users/rdobrins/followers","following_url":"https://api.github.com/users/rdobrins/following{/other_user}","gists_url":"https://api.github.com/users/rdobrins/gists{/gist_id}","starred_url":"https://api.github.com/users/rdobrins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rdobrins/subscriptions","organizations_url":"https://api.github.com/users/rdobrins/orgs","repos_url":"https://api.github.com/users/rdobrins/repos","events_url":"https://api.github.com/users/rdobrins/events{/privacy}","received_events_url":"https://api.github.com/users/rdobrins/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rdobrins/subway_review_site","description":"","fork":false,"url":"https://api.github.com/repos/rdobrins/subway_review_site","forks_url":"https://api.github.com/repos/rdobrins/subway_review_site/forks","keys_url":"https://api.github.com/repos/rdobrins/subway_review_site/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rdobrins/subway_review_site/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rdobrins/subway_review_site/teams","hooks_url":"https://api.github.com/repos/rdobrins/subway_review_site/hooks","issue_events_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/events{/number}","events_url":"https://api.github.com/repos/rdobrins/subway_review_site/events","assignees_url":"https://api.github.com/repos/rdobrins/subway_review_site/assignees{/user}","branches_url":"https://api.github.com/repos/rdobrins/subway_review_site/branches{/branch}","tags_url":"https://api.github.com/repos/rdobrins/subway_review_site/tags","blobs_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/refs{/sha}","trees_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rdobrins/subway_review_site/statuses/{sha}","languages_url":"https://api.github.com/repos/rdobrins/subway_review_site/languages","stargazers_url":"https://api.github.com/repos/rdobrins/subway_review_site/stargazers","contributors_url":"https://api.github.com/repos/rdobrins/subway_review_site/contributors","subscribers_url":"https://api.github.com/repos/rdobrins/subway_review_site/subscribers","subscription_url":"https://api.github.com/repos/rdobrins/subway_review_site/subscription","commits_url":"https://api.github.com/repos/rdobrins/subway_review_site/commits{/sha}","git_commits_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/commits{/sha}","comments_url":"https://api.github.com/repos/rdobrins/subway_review_site/comments{/number}","issue_comment_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/comments{/number}","contents_url":"https://api.github.com/repos/rdobrins/subway_review_site/contents/{+path}","compare_url":"https://api.github.com/repos/rdobrins/subway_review_site/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rdobrins/subway_review_site/merges","archive_url":"https://api.github.com/repos/rdobrins/subway_review_site/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rdobrins/subway_review_site/downloads","issues_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues{/number}","pulls_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls{/number}","milestones_url":"https://api.github.com/repos/rdobrins/subway_review_site/milestones{/number}","notifications_url":"https://api.github.com/repos/rdobrins/subway_review_site/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rdobrins/subway_review_site/labels{/name}","releases_url":"https://api.github.com/repos/rdobrins/subway_review_site/releases{/id}","created_at":"2016-01-04T15:42:00Z","updated_at":"2016-01-11T20:19:02Z","pushed_at":"2016-01-13T16:46:30Z","git_url":"git://github.com/rdobrins/subway_review_site.git","ssh_url":"git@github.com:rdobrins/subway_review_site.git","clone_url":"https://github.com/rdobrins/subway_review_site.git","svn_url":"https://github.com/rdobrins/subway_review_site","homepage":null,"size":808,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"rdobrins:master","ref":"master","sha":"4f484dd9b6748c0babe535ac1c574f22e7fa233e","user":{"login":"rdobrins","id":13757640,"avatar_url":"https://avatars.githubusercontent.com/u/13757640?v=3","gravatar_id":"","url":"https://api.github.com/users/rdobrins","html_url":"https://github.com/rdobrins","followers_url":"https://api.github.com/users/rdobrins/followers","following_url":"https://api.github.com/users/rdobrins/following{/other_user}","gists_url":"https://api.github.com/users/rdobrins/gists{/gist_id}","starred_url":"https://api.github.com/users/rdobrins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rdobrins/subscriptions","organizations_url":"https://api.github.com/users/rdobrins/orgs","repos_url":"https://api.github.com/users/rdobrins/repos","events_url":"https://api.github.com/users/rdobrins/events{/privacy}","received_events_url":"https://api.github.com/users/rdobrins/received_events","type":"User","site_admin":false},"repo":{"id":49006212,"name":"subway_review_site","full_name":"rdobrins/subway_review_site","owner":{"login":"rdobrins","id":13757640,"avatar_url":"https://avatars.githubusercontent.com/u/13757640?v=3","gravatar_id":"","url":"https://api.github.com/users/rdobrins","html_url":"https://github.com/rdobrins","followers_url":"https://api.github.com/users/rdobrins/followers","following_url":"https://api.github.com/users/rdobrins/following{/other_user}","gists_url":"https://api.github.com/users/rdobrins/gists{/gist_id}","starred_url":"https://api.github.com/users/rdobrins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rdobrins/subscriptions","organizations_url":"https://api.github.com/users/rdobrins/orgs","repos_url":"https://api.github.com/users/rdobrins/repos","events_url":"https://api.github.com/users/rdobrins/events{/privacy}","received_events_url":"https://api.github.com/users/rdobrins/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rdobrins/subway_review_site","description":"","fork":false,"url":"https://api.github.com/repos/rdobrins/subway_review_site","forks_url":"https://api.github.com/repos/rdobrins/subway_review_site/forks","keys_url":"https://api.github.com/repos/rdobrins/subway_review_site/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rdobrins/subway_review_site/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rdobrins/subway_review_site/teams","hooks_url":"https://api.github.com/repos/rdobrins/subway_review_site/hooks","issue_events_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/events{/number}","events_url":"https://api.github.com/repos/rdobrins/subway_review_site/events","assignees_url":"https://api.github.com/repos/rdobrins/subway_review_site/assignees{/user}","branches_url":"https://api.github.com/repos/rdobrins/subway_review_site/branches{/branch}","tags_url":"https://api.github.com/repos/rdobrins/subway_review_site/tags","blobs_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/refs{/sha}","trees_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rdobrins/subway_review_site/statuses/{sha}","languages_url":"https://api.github.com/repos/rdobrins/subway_review_site/languages","stargazers_url":"https://api.github.com/repos/rdobrins/subway_review_site/stargazers","contributors_url":"https://api.github.com/repos/rdobrins/subway_review_site/contributors","subscribers_url":"https://api.github.com/repos/rdobrins/subway_review_site/subscribers","subscription_url":"https://api.github.com/repos/rdobrins/subway_review_site/subscription","commits_url":"https://api.github.com/repos/rdobrins/subway_review_site/commits{/sha}","git_commits_url":"https://api.github.com/repos/rdobrins/subway_review_site/git/commits{/sha}","comments_url":"https://api.github.com/repos/rdobrins/subway_review_site/comments{/number}","issue_comment_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues/comments{/number}","contents_url":"https://api.github.com/repos/rdobrins/subway_review_site/contents/{+path}","compare_url":"https://api.github.com/repos/rdobrins/subway_review_site/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rdobrins/subway_review_site/merges","archive_url":"https://api.github.com/repos/rdobrins/subway_review_site/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rdobrins/subway_review_site/downloads","issues_url":"https://api.github.com/repos/rdobrins/subway_review_site/issues{/number}","pulls_url":"https://api.github.com/repos/rdobrins/subway_review_site/pulls{/number}","milestones_url":"https://api.github.com/repos/rdobrins/subway_review_site/milestones{/number}","notifications_url":"https://api.github.com/repos/rdobrins/subway_review_site/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rdobrins/subway_review_site/labels{/name}","releases_url":"https://api.github.com/repos/rdobrins/subway_review_site/releases{/id}","created_at":"2016-01-04T15:42:00Z","updated_at":"2016-01-11T20:19:02Z","pushed_at":"2016-01-13T16:46:30Z","git_url":"git://github.com/rdobrins/subway_review_site.git","ssh_url":"git@github.com:rdobrins/subway_review_site.git","clone_url":"https://github.com/rdobrins/subway_review_site.git","svn_url":"https://github.com/rdobrins/subway_review_site","homepage":null,"size":808,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24"},"html":{"href":"https://github.com/rdobrins/subway_review_site/pull/24"},"issue":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/issues/24"},"comments":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/issues/24/comments"},"review_comments":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24/comments"},"review_comment":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/pulls/24/commits"},"statuses":{"href":"https://api.github.com/repos/rdobrins/subway_review_site/statuses/47e2abe38a1645576e980b4036a962f3f0095a60"}}}}