{"action":"created","comment":{"url":"https://api.github.com/repos/alx-t/flashcards/pulls/comments/27696118","id":27696118,"diff_hunk":"@@ -0,0 +1,46 @@\n+class PacksController < ApplicationController\r\n+  before_action :set_pack, only: [:show, :edit, :update, :destroy]\r\n+\r\n+  def index\r\n+    @packs = current_user.packs\r\n+  end\r\n+\r\n+  def new\r\n+    @pack = current_user.packs.new\r\n+  end\r\n+\r\n+  def create\r\n+    @pack = current_user.packs.build(pack_params)\r\n+    if @pack.save\r\n+      @pack.user.update_attribute(:current_pack, @pack) if pack_params[\"current\"] == \"1\"\r","path":"app/controllers/packs_controller.rb","position":15,"original_position":15,"commit_id":"064b80e7fa6c081a4754b86285c616329e17a31e","original_commit_id":"064b80e7fa6c081a4754b86285c616329e17a31e","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":"Line is too long. [88/80]","created_at":"2015-04-02T20:53:56Z","updated_at":"2015-04-02T20:53:56Z","html_url":"https://github.com/alx-t/flashcards/pull/11#discussion_r27696118","pull_request_url":"https://api.github.com/repos/alx-t/flashcards/pulls/11","_links":{"self":{"href":"https://api.github.com/repos/alx-t/flashcards/pulls/comments/27696118"},"html":{"href":"https://github.com/alx-t/flashcards/pull/11#discussion_r27696118"},"pull_request":{"href":"https://api.github.com/repos/alx-t/flashcards/pulls/11"}}},"pull_request":{"url":"https://api.github.com/repos/alx-t/flashcards/pulls/11","id":32549256,"html_url":"https://github.com/alx-t/flashcards/pull/11","diff_url":"https://github.com/alx-t/flashcards/pull/11.diff","patch_url":"https://github.com/alx-t/flashcards/pull/11.patch","issue_url":"https://api.github.com/repos/alx-t/flashcards/issues/11","number":11,"state":"open","locked":false,"title":"add packs","user":{"login":"alx-t","id":11555672,"avatar_url":"https://avatars.githubusercontent.com/u/11555672?v=3","gravatar_id":"","url":"https://api.github.com/users/alx-t","html_url":"https://github.com/alx-t","followers_url":"https://api.github.com/users/alx-t/followers","following_url":"https://api.github.com/users/alx-t/following{/other_user}","gists_url":"https://api.github.com/users/alx-t/gists{/gist_id}","starred_url":"https://api.github.com/users/alx-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alx-t/subscriptions","organizations_url":"https://api.github.com/users/alx-t/orgs","repos_url":"https://api.github.com/users/alx-t/repos","events_url":"https://api.github.com/users/alx-t/events{/privacy}","received_events_url":"https://api.github.com/users/alx-t/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-04-02T20:53:52Z","updated_at":"2015-04-02T20:53:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fcb1bcbcaabc6642b4512d50189c9d5dae0dcdbc","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/alx-t/flashcards/pulls/11/commits","review_comments_url":"https://api.github.com/repos/alx-t/flashcards/pulls/11/comments","review_comment_url":"https://api.github.com/repos/alx-t/flashcards/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alx-t/flashcards/issues/11/comments","statuses_url":"https://api.github.com/repos/alx-t/flashcards/statuses/064b80e7fa6c081a4754b86285c616329e17a31e","head":{"label":"alx-t:eleventh-task","ref":"eleventh-task","sha":"064b80e7fa6c081a4754b86285c616329e17a31e","user":{"login":"alx-t","id":11555672,"avatar_url":"https://avatars.githubusercontent.com/u/11555672?v=3","gravatar_id":"","url":"https://api.github.com/users/alx-t","html_url":"https://github.com/alx-t","followers_url":"https://api.github.com/users/alx-t/followers","following_url":"https://api.github.com/users/alx-t/following{/other_user}","gists_url":"https://api.github.com/users/alx-t/gists{/gist_id}","starred_url":"https://api.github.com/users/alx-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alx-t/subscriptions","organizations_url":"https://api.github.com/users/alx-t/orgs","repos_url":"https://api.github.com/users/alx-t/repos","events_url":"https://api.github.com/users/alx-t/events{/privacy}","received_events_url":"https://api.github.com/users/alx-t/received_events","type":"User","site_admin":false},"repo":{"id":32519756,"name":"flashcards","full_name":"alx-t/flashcards","owner":{"login":"alx-t","id":11555672,"avatar_url":"https://avatars.githubusercontent.com/u/11555672?v=3","gravatar_id":"","url":"https://api.github.com/users/alx-t","html_url":"https://github.com/alx-t","followers_url":"https://api.github.com/users/alx-t/followers","following_url":"https://api.github.com/users/alx-t/following{/other_user}","gists_url":"https://api.github.com/users/alx-t/gists{/gist_id}","starred_url":"https://api.github.com/users/alx-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alx-t/subscriptions","organizations_url":"https://api.github.com/users/alx-t/orgs","repos_url":"https://api.github.com/users/alx-t/repos","events_url":"https://api.github.com/users/alx-t/events{/privacy}","received_events_url":"https://api.github.com/users/alx-t/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alx-t/flashcards","description":"","fork":false,"url":"https://api.github.com/repos/alx-t/flashcards","forks_url":"https://api.github.com/repos/alx-t/flashcards/forks","keys_url":"https://api.github.com/repos/alx-t/flashcards/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alx-t/flashcards/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alx-t/flashcards/teams","hooks_url":"https://api.github.com/repos/alx-t/flashcards/hooks","issue_events_url":"https://api.github.com/repos/alx-t/flashcards/issues/events{/number}","events_url":"https://api.github.com/repos/alx-t/flashcards/events","assignees_url":"https://api.github.com/repos/alx-t/flashcards/assignees{/user}","branches_url":"https://api.github.com/repos/alx-t/flashcards/branches{/branch}","tags_url":"https://api.github.com/repos/alx-t/flashcards/tags","blobs_url":"https://api.github.com/repos/alx-t/flashcards/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alx-t/flashcards/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alx-t/flashcards/git/refs{/sha}","trees_url":"https://api.github.com/repos/alx-t/flashcards/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alx-t/flashcards/statuses/{sha}","languages_url":"https://api.github.com/repos/alx-t/flashcards/languages","stargazers_url":"https://api.github.com/repos/alx-t/flashcards/stargazers","contributors_url":"https://api.github.com/repos/alx-t/flashcards/contributors","subscribers_url":"https://api.github.com/repos/alx-t/flashcards/subscribers","subscription_url":"https://api.github.com/repos/alx-t/flashcards/subscription","commits_url":"https://api.github.com/repos/alx-t/flashcards/commits{/sha}","git_commits_url":"https://api.github.com/repos/alx-t/flashcards/git/commits{/sha}","comments_url":"https://api.github.com/repos/alx-t/flashcards/comments{/number}","issue_comment_url":"https://api.github.com/repos/alx-t/flashcards/issues/comments{/number}","contents_url":"https://api.github.com/repos/alx-t/flashcards/contents/{+path}","compare_url":"https://api.github.com/repos/alx-t/flashcards/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alx-t/flashcards/merges","archive_url":"https://api.github.com/repos/alx-t/flashcards/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alx-t/flashcards/downloads","issues_url":"https://api.github.com/repos/alx-t/flashcards/issues{/number}","pulls_url":"https://api.github.com/repos/alx-t/flashcards/pulls{/number}","milestones_url":"https://api.github.com/repos/alx-t/flashcards/milestones{/number}","notifications_url":"https://api.github.com/repos/alx-t/flashcards/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alx-t/flashcards/labels{/name}","releases_url":"https://api.github.com/repos/alx-t/flashcards/releases{/id}","created_at":"2015-03-19T12:24:25Z","updated_at":"2015-03-30T21:50:21Z","pushed_at":"2015-04-02T20:53:53Z","git_url":"git://github.com/alx-t/flashcards.git","ssh_url":"git@github.com:alx-t/flashcards.git","clone_url":"https://github.com/alx-t/flashcards.git","svn_url":"https://github.com/alx-t/flashcards","homepage":null,"size":492,"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":"alx-t:master","ref":"master","sha":"f410402aec86c61d4672e500dbf4b8d23fc1a7ca","user":{"login":"alx-t","id":11555672,"avatar_url":"https://avatars.githubusercontent.com/u/11555672?v=3","gravatar_id":"","url":"https://api.github.com/users/alx-t","html_url":"https://github.com/alx-t","followers_url":"https://api.github.com/users/alx-t/followers","following_url":"https://api.github.com/users/alx-t/following{/other_user}","gists_url":"https://api.github.com/users/alx-t/gists{/gist_id}","starred_url":"https://api.github.com/users/alx-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alx-t/subscriptions","organizations_url":"https://api.github.com/users/alx-t/orgs","repos_url":"https://api.github.com/users/alx-t/repos","events_url":"https://api.github.com/users/alx-t/events{/privacy}","received_events_url":"https://api.github.com/users/alx-t/received_events","type":"User","site_admin":false},"repo":{"id":32519756,"name":"flashcards","full_name":"alx-t/flashcards","owner":{"login":"alx-t","id":11555672,"avatar_url":"https://avatars.githubusercontent.com/u/11555672?v=3","gravatar_id":"","url":"https://api.github.com/users/alx-t","html_url":"https://github.com/alx-t","followers_url":"https://api.github.com/users/alx-t/followers","following_url":"https://api.github.com/users/alx-t/following{/other_user}","gists_url":"https://api.github.com/users/alx-t/gists{/gist_id}","starred_url":"https://api.github.com/users/alx-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alx-t/subscriptions","organizations_url":"https://api.github.com/users/alx-t/orgs","repos_url":"https://api.github.com/users/alx-t/repos","events_url":"https://api.github.com/users/alx-t/events{/privacy}","received_events_url":"https://api.github.com/users/alx-t/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alx-t/flashcards","description":"","fork":false,"url":"https://api.github.com/repos/alx-t/flashcards","forks_url":"https://api.github.com/repos/alx-t/flashcards/forks","keys_url":"https://api.github.com/repos/alx-t/flashcards/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alx-t/flashcards/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alx-t/flashcards/teams","hooks_url":"https://api.github.com/repos/alx-t/flashcards/hooks","issue_events_url":"https://api.github.com/repos/alx-t/flashcards/issues/events{/number}","events_url":"https://api.github.com/repos/alx-t/flashcards/events","assignees_url":"https://api.github.com/repos/alx-t/flashcards/assignees{/user}","branches_url":"https://api.github.com/repos/alx-t/flashcards/branches{/branch}","tags_url":"https://api.github.com/repos/alx-t/flashcards/tags","blobs_url":"https://api.github.com/repos/alx-t/flashcards/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alx-t/flashcards/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alx-t/flashcards/git/refs{/sha}","trees_url":"https://api.github.com/repos/alx-t/flashcards/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alx-t/flashcards/statuses/{sha}","languages_url":"https://api.github.com/repos/alx-t/flashcards/languages","stargazers_url":"https://api.github.com/repos/alx-t/flashcards/stargazers","contributors_url":"https://api.github.com/repos/alx-t/flashcards/contributors","subscribers_url":"https://api.github.com/repos/alx-t/flashcards/subscribers","subscription_url":"https://api.github.com/repos/alx-t/flashcards/subscription","commits_url":"https://api.github.com/repos/alx-t/flashcards/commits{/sha}","git_commits_url":"https://api.github.com/repos/alx-t/flashcards/git/commits{/sha}","comments_url":"https://api.github.com/repos/alx-t/flashcards/comments{/number}","issue_comment_url":"https://api.github.com/repos/alx-t/flashcards/issues/comments{/number}","contents_url":"https://api.github.com/repos/alx-t/flashcards/contents/{+path}","compare_url":"https://api.github.com/repos/alx-t/flashcards/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alx-t/flashcards/merges","archive_url":"https://api.github.com/repos/alx-t/flashcards/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alx-t/flashcards/downloads","issues_url":"https://api.github.com/repos/alx-t/flashcards/issues{/number}","pulls_url":"https://api.github.com/repos/alx-t/flashcards/pulls{/number}","milestones_url":"https://api.github.com/repos/alx-t/flashcards/milestones{/number}","notifications_url":"https://api.github.com/repos/alx-t/flashcards/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alx-t/flashcards/labels{/name}","releases_url":"https://api.github.com/repos/alx-t/flashcards/releases{/id}","created_at":"2015-03-19T12:24:25Z","updated_at":"2015-03-30T21:50:21Z","pushed_at":"2015-04-02T20:53:53Z","git_url":"git://github.com/alx-t/flashcards.git","ssh_url":"git@github.com:alx-t/flashcards.git","clone_url":"https://github.com/alx-t/flashcards.git","svn_url":"https://github.com/alx-t/flashcards","homepage":null,"size":492,"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/alx-t/flashcards/pulls/11"},"html":{"href":"https://github.com/alx-t/flashcards/pull/11"},"issue":{"href":"https://api.github.com/repos/alx-t/flashcards/issues/11"},"comments":{"href":"https://api.github.com/repos/alx-t/flashcards/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/alx-t/flashcards/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/alx-t/flashcards/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alx-t/flashcards/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/alx-t/flashcards/statuses/064b80e7fa6c081a4754b86285c616329e17a31e"}}}}