{"action":"created","comment":{"url":"https://api.github.com/repos/tadp/furry_avocado/pulls/comments/27094011","id":27094011,"diff_hunk":"@@ -0,0 +1,45 @@\n+class QuestionsController < ApplicationController\n+  before_action :ensure_current_user\n+\n+  def new\n+    @question = Question.new\n+  end\n+\n+  def create\n+    @question = current_user.questions.new(\n+      question_params.merge({\n+        vote_rating: 0,\n+        view_count: 0\n+      })\n+    )\n+\n+    if @question.save\n+      find_or_create_tags_and_tag_assignments\n+      redirect_to question_url(@question)\n+    else\n+      render :new\n+    end\n+  end\n+\n+  def show\n+    @question = Question.includes(:tags, :tag_assignments).find(params[:id])\n+    @question.view_count += 1","path":"app/controllers/questions_controller.rb","position":26,"original_position":26,"commit_id":"01f6d9b55d967907e6de98fa377d2ad3a1ac5cf0","original_commit_id":"01f6d9b55d967907e6de98fa377d2ad3a1ac5cf0","user":{"login":"jettaprime","id":7613236,"avatar_url":"https://avatars.githubusercontent.com/u/7613236?v=3","gravatar_id":"","url":"https://api.github.com/users/jettaprime","html_url":"https://github.com/jettaprime","followers_url":"https://api.github.com/users/jettaprime/followers","following_url":"https://api.github.com/users/jettaprime/following{/other_user}","gists_url":"https://api.github.com/users/jettaprime/gists{/gist_id}","starred_url":"https://api.github.com/users/jettaprime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jettaprime/subscriptions","organizations_url":"https://api.github.com/users/jettaprime/orgs","repos_url":"https://api.github.com/users/jettaprime/repos","events_url":"https://api.github.com/users/jettaprime/events{/privacy}","received_events_url":"https://api.github.com/users/jettaprime/received_events","type":"User","site_admin":false},"body":"Remove line 26 + 27 because it is a GET request.","created_at":"2015-03-25T04:11:18Z","updated_at":"2015-03-25T04:11:18Z","html_url":"https://github.com/tadp/furry_avocado/pull/2#discussion_r27094011","pull_request_url":"https://api.github.com/repos/tadp/furry_avocado/pulls/2","_links":{"self":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/comments/27094011"},"html":{"href":"https://github.com/tadp/furry_avocado/pull/2#discussion_r27094011"},"pull_request":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/2"}}},"pull_request":{"url":"https://api.github.com/repos/tadp/furry_avocado/pulls/2","id":31884421,"html_url":"https://github.com/tadp/furry_avocado/pull/2","diff_url":"https://github.com/tadp/furry_avocado/pull/2.diff","patch_url":"https://github.com/tadp/furry_avocado/pull/2.patch","issue_url":"https://api.github.com/repos/tadp/furry_avocado/issues/2","number":2,"state":"open","locked":false,"title":"Question","user":{"login":"jettaprime","id":7613236,"avatar_url":"https://avatars.githubusercontent.com/u/7613236?v=3","gravatar_id":"","url":"https://api.github.com/users/jettaprime","html_url":"https://github.com/jettaprime","followers_url":"https://api.github.com/users/jettaprime/followers","following_url":"https://api.github.com/users/jettaprime/following{/other_user}","gists_url":"https://api.github.com/users/jettaprime/gists{/gist_id}","starred_url":"https://api.github.com/users/jettaprime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jettaprime/subscriptions","organizations_url":"https://api.github.com/users/jettaprime/orgs","repos_url":"https://api.github.com/users/jettaprime/repos","events_url":"https://api.github.com/users/jettaprime/events{/privacy}","received_events_url":"https://api.github.com/users/jettaprime/received_events","type":"User","site_admin":false},"body":"Tad, I still have yet to do tests for the new voting and tagging features.\r\n\r\nThere are some issues of security and metaprogramming that I wanted to address with you, because I might need some of your insight on those things.\r\n\r\nFrom a basic level/viewpoint, it works. I feel maybe, if it's at all possible, it'd be nice if we could do a code review together.","created_at":"2015-03-25T00:45:38Z","updated_at":"2015-03-25T04:11:18Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7a6b0b032c1c61f9f92e8a1b569caf18464909a1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/tadp/furry_avocado/pulls/2/commits","review_comments_url":"https://api.github.com/repos/tadp/furry_avocado/pulls/2/comments","review_comment_url":"https://api.github.com/repos/tadp/furry_avocado/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tadp/furry_avocado/issues/2/comments","statuses_url":"https://api.github.com/repos/tadp/furry_avocado/statuses/01f6d9b55d967907e6de98fa377d2ad3a1ac5cf0","head":{"label":"tadp:Question","ref":"Question","sha":"01f6d9b55d967907e6de98fa377d2ad3a1ac5cf0","user":{"login":"tadp","id":4078758,"avatar_url":"https://avatars.githubusercontent.com/u/4078758?v=3","gravatar_id":"","url":"https://api.github.com/users/tadp","html_url":"https://github.com/tadp","followers_url":"https://api.github.com/users/tadp/followers","following_url":"https://api.github.com/users/tadp/following{/other_user}","gists_url":"https://api.github.com/users/tadp/gists{/gist_id}","starred_url":"https://api.github.com/users/tadp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tadp/subscriptions","organizations_url":"https://api.github.com/users/tadp/orgs","repos_url":"https://api.github.com/users/tadp/repos","events_url":"https://api.github.com/users/tadp/events{/privacy}","received_events_url":"https://api.github.com/users/tadp/received_events","type":"User","site_admin":false},"repo":{"id":29166051,"name":"furry_avocado","full_name":"tadp/furry_avocado","owner":{"login":"tadp","id":4078758,"avatar_url":"https://avatars.githubusercontent.com/u/4078758?v=3","gravatar_id":"","url":"https://api.github.com/users/tadp","html_url":"https://github.com/tadp","followers_url":"https://api.github.com/users/tadp/followers","following_url":"https://api.github.com/users/tadp/following{/other_user}","gists_url":"https://api.github.com/users/tadp/gists{/gist_id}","starred_url":"https://api.github.com/users/tadp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tadp/subscriptions","organizations_url":"https://api.github.com/users/tadp/orgs","repos_url":"https://api.github.com/users/tadp/repos","events_url":"https://api.github.com/users/tadp/events{/privacy}","received_events_url":"https://api.github.com/users/tadp/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tadp/furry_avocado","description":"","fork":false,"url":"https://api.github.com/repos/tadp/furry_avocado","forks_url":"https://api.github.com/repos/tadp/furry_avocado/forks","keys_url":"https://api.github.com/repos/tadp/furry_avocado/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tadp/furry_avocado/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tadp/furry_avocado/teams","hooks_url":"https://api.github.com/repos/tadp/furry_avocado/hooks","issue_events_url":"https://api.github.com/repos/tadp/furry_avocado/issues/events{/number}","events_url":"https://api.github.com/repos/tadp/furry_avocado/events","assignees_url":"https://api.github.com/repos/tadp/furry_avocado/assignees{/user}","branches_url":"https://api.github.com/repos/tadp/furry_avocado/branches{/branch}","tags_url":"https://api.github.com/repos/tadp/furry_avocado/tags","blobs_url":"https://api.github.com/repos/tadp/furry_avocado/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tadp/furry_avocado/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tadp/furry_avocado/git/refs{/sha}","trees_url":"https://api.github.com/repos/tadp/furry_avocado/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tadp/furry_avocado/statuses/{sha}","languages_url":"https://api.github.com/repos/tadp/furry_avocado/languages","stargazers_url":"https://api.github.com/repos/tadp/furry_avocado/stargazers","contributors_url":"https://api.github.com/repos/tadp/furry_avocado/contributors","subscribers_url":"https://api.github.com/repos/tadp/furry_avocado/subscribers","subscription_url":"https://api.github.com/repos/tadp/furry_avocado/subscription","commits_url":"https://api.github.com/repos/tadp/furry_avocado/commits{/sha}","git_commits_url":"https://api.github.com/repos/tadp/furry_avocado/git/commits{/sha}","comments_url":"https://api.github.com/repos/tadp/furry_avocado/comments{/number}","issue_comment_url":"https://api.github.com/repos/tadp/furry_avocado/issues/comments{/number}","contents_url":"https://api.github.com/repos/tadp/furry_avocado/contents/{+path}","compare_url":"https://api.github.com/repos/tadp/furry_avocado/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tadp/furry_avocado/merges","archive_url":"https://api.github.com/repos/tadp/furry_avocado/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tadp/furry_avocado/downloads","issues_url":"https://api.github.com/repos/tadp/furry_avocado/issues{/number}","pulls_url":"https://api.github.com/repos/tadp/furry_avocado/pulls{/number}","milestones_url":"https://api.github.com/repos/tadp/furry_avocado/milestones{/number}","notifications_url":"https://api.github.com/repos/tadp/furry_avocado/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tadp/furry_avocado/labels{/name}","releases_url":"https://api.github.com/repos/tadp/furry_avocado/releases{/id}","created_at":"2015-01-13T01:18:51Z","updated_at":"2015-03-19T04:39:07Z","pushed_at":"2015-03-25T00:45:39Z","git_url":"git://github.com/tadp/furry_avocado.git","ssh_url":"git@github.com:tadp/furry_avocado.git","clone_url":"https://github.com/tadp/furry_avocado.git","svn_url":"https://github.com/tadp/furry_avocado","homepage":null,"size":208,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"tadp:master","ref":"master","sha":"bc32bbe3b6399827dad0bdeef2d2cf121caaf049","user":{"login":"tadp","id":4078758,"avatar_url":"https://avatars.githubusercontent.com/u/4078758?v=3","gravatar_id":"","url":"https://api.github.com/users/tadp","html_url":"https://github.com/tadp","followers_url":"https://api.github.com/users/tadp/followers","following_url":"https://api.github.com/users/tadp/following{/other_user}","gists_url":"https://api.github.com/users/tadp/gists{/gist_id}","starred_url":"https://api.github.com/users/tadp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tadp/subscriptions","organizations_url":"https://api.github.com/users/tadp/orgs","repos_url":"https://api.github.com/users/tadp/repos","events_url":"https://api.github.com/users/tadp/events{/privacy}","received_events_url":"https://api.github.com/users/tadp/received_events","type":"User","site_admin":false},"repo":{"id":29166051,"name":"furry_avocado","full_name":"tadp/furry_avocado","owner":{"login":"tadp","id":4078758,"avatar_url":"https://avatars.githubusercontent.com/u/4078758?v=3","gravatar_id":"","url":"https://api.github.com/users/tadp","html_url":"https://github.com/tadp","followers_url":"https://api.github.com/users/tadp/followers","following_url":"https://api.github.com/users/tadp/following{/other_user}","gists_url":"https://api.github.com/users/tadp/gists{/gist_id}","starred_url":"https://api.github.com/users/tadp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tadp/subscriptions","organizations_url":"https://api.github.com/users/tadp/orgs","repos_url":"https://api.github.com/users/tadp/repos","events_url":"https://api.github.com/users/tadp/events{/privacy}","received_events_url":"https://api.github.com/users/tadp/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tadp/furry_avocado","description":"","fork":false,"url":"https://api.github.com/repos/tadp/furry_avocado","forks_url":"https://api.github.com/repos/tadp/furry_avocado/forks","keys_url":"https://api.github.com/repos/tadp/furry_avocado/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tadp/furry_avocado/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tadp/furry_avocado/teams","hooks_url":"https://api.github.com/repos/tadp/furry_avocado/hooks","issue_events_url":"https://api.github.com/repos/tadp/furry_avocado/issues/events{/number}","events_url":"https://api.github.com/repos/tadp/furry_avocado/events","assignees_url":"https://api.github.com/repos/tadp/furry_avocado/assignees{/user}","branches_url":"https://api.github.com/repos/tadp/furry_avocado/branches{/branch}","tags_url":"https://api.github.com/repos/tadp/furry_avocado/tags","blobs_url":"https://api.github.com/repos/tadp/furry_avocado/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tadp/furry_avocado/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tadp/furry_avocado/git/refs{/sha}","trees_url":"https://api.github.com/repos/tadp/furry_avocado/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tadp/furry_avocado/statuses/{sha}","languages_url":"https://api.github.com/repos/tadp/furry_avocado/languages","stargazers_url":"https://api.github.com/repos/tadp/furry_avocado/stargazers","contributors_url":"https://api.github.com/repos/tadp/furry_avocado/contributors","subscribers_url":"https://api.github.com/repos/tadp/furry_avocado/subscribers","subscription_url":"https://api.github.com/repos/tadp/furry_avocado/subscription","commits_url":"https://api.github.com/repos/tadp/furry_avocado/commits{/sha}","git_commits_url":"https://api.github.com/repos/tadp/furry_avocado/git/commits{/sha}","comments_url":"https://api.github.com/repos/tadp/furry_avocado/comments{/number}","issue_comment_url":"https://api.github.com/repos/tadp/furry_avocado/issues/comments{/number}","contents_url":"https://api.github.com/repos/tadp/furry_avocado/contents/{+path}","compare_url":"https://api.github.com/repos/tadp/furry_avocado/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tadp/furry_avocado/merges","archive_url":"https://api.github.com/repos/tadp/furry_avocado/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tadp/furry_avocado/downloads","issues_url":"https://api.github.com/repos/tadp/furry_avocado/issues{/number}","pulls_url":"https://api.github.com/repos/tadp/furry_avocado/pulls{/number}","milestones_url":"https://api.github.com/repos/tadp/furry_avocado/milestones{/number}","notifications_url":"https://api.github.com/repos/tadp/furry_avocado/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tadp/furry_avocado/labels{/name}","releases_url":"https://api.github.com/repos/tadp/furry_avocado/releases{/id}","created_at":"2015-01-13T01:18:51Z","updated_at":"2015-03-19T04:39:07Z","pushed_at":"2015-03-25T00:45:39Z","git_url":"git://github.com/tadp/furry_avocado.git","ssh_url":"git@github.com:tadp/furry_avocado.git","clone_url":"https://github.com/tadp/furry_avocado.git","svn_url":"https://github.com/tadp/furry_avocado","homepage":null,"size":208,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/2"},"html":{"href":"https://github.com/tadp/furry_avocado/pull/2"},"issue":{"href":"https://api.github.com/repos/tadp/furry_avocado/issues/2"},"comments":{"href":"https://api.github.com/repos/tadp/furry_avocado/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tadp/furry_avocado/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/tadp/furry_avocado/statuses/01f6d9b55d967907e6de98fa377d2ad3a1ac5cf0"}}}}