GitHub PullRequestReviewCommentEvent at 2014-07-30 14:29:08
Repository: wastr
Actor: garthgoldwater
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/amZotti/wastr/pulls/comments/15586498","id":15586498,"diff_hunk":"@@ -1,7 +1,13 @@\n class Post < ActiveRecord::Base\n+  belongs_to :user\n+  has_many :comments, dependent: :destroy\n+  has_many :replies, as: :parent, class_name: \"Comment\"\n+\n+  validates :user, presence: true\n   validates :title, presence: true\n   validates :body, presence: true\n \n-  belongs_to :user\n-  has_many :comments, dependent: :destroy\n+  def post","path":"app/models/post.rb","position":12,"original_position":12,"commit_id":"e6ad65f02c4bea5609b11e5924ba2a2913f17874","original_commit_id":"e6ad65f02c4bea5609b11e5924ba2a2913f17874","user":{"login":"garthgoldwater","id":7171900,"avatar_url":"https://avatars.githubusercontent.com/u/7171900?v=1","gravatar_id":"867a874aceb6e0f0405097b0584853c1","url":"https://api.github.com/users/garthgoldwater","html_url":"https://github.com/garthgoldwater","followers_url":"https://api.github.com/users/garthgoldwater/followers","following_url":"https://api.github.com/users/garthgoldwater/following{/other_user}","gists_url":"https://api.github.com/users/garthgoldwater/gists{/gist_id}","starred_url":"https://api.github.com/users/garthgoldwater/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/garthgoldwater/subscriptions","organizations_url":"https://api.github.com/users/garthgoldwater/orgs","repos_url":"https://api.github.com/users/garthgoldwater/repos","events_url":"https://api.github.com/users/garthgoldwater/events{/privacy}","received_events_url":"https://api.github.com/users/garthgoldwater/received_events","type":"User","site_admin":false},"body":"it's so that parent.post in comment_controller can tell don't ask -- see line 4 in comments controller","created_at":"2014-07-30T14:29:08Z","updated_at":"2014-07-30T14:29:08Z","html_url":"https://github.com/amZotti/wastr/pull/7#discussion_r15586498","pull_request_url":"https://api.github.com/repos/amZotti/wastr/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/amZotti/wastr/pulls/comments/15586498"},"html":{"href":"https://github.com/amZotti/wastr/pull/7#discussion_r15586498"},"pull_request":{"href":"https://api.github.com/repos/amZotti/wastr/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/amZotti/wastr/pulls/7","id":19051852,"html_url":"https://github.com/amZotti/wastr/pull/7","diff_url":"https://github.com/amZotti/wastr/pull/7.diff","patch_url":"https://github.com/amZotti/wastr/pull/7.patch","issue_url":"https://api.github.com/repos/amZotti/wastr/issues/7","number":7,"state":"open","title":"Let users reply to comments","user":{"login":"garthgoldwater","id":7171900,"avatar_url":"https://avatars.githubusercontent.com/u/7171900?v=1","gravatar_id":"867a874aceb6e0f0405097b0584853c1","url":"https://api.github.com/users/garthgoldwater","html_url":"https://github.com/garthgoldwater","followers_url":"https://api.github.com/users/garthgoldwater/followers","following_url":"https://api.github.com/users/garthgoldwater/following{/other_user}","gists_url":"https://api.github.com/users/garthgoldwater/gists{/gist_id}","starred_url":"https://api.github.com/users/garthgoldwater/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/garthgoldwater/subscriptions","organizations_url":"https://api.github.com/users/garthgoldwater/orgs","repos_url":"https://api.github.com/users/garthgoldwater/repos","events_url":"https://api.github.com/users/garthgoldwater/events{/privacy}","received_events_url":"https://api.github.com/users/garthgoldwater/received_events","type":"User","site_admin":false},"body":"Previously: comments only replied to posts\r\nProblem: reddit has really neat threaded conversations of comments replying to comments replying to comments, replying to (etc)\r\nSolution: \r\n-make comments belong to a polymorphic \"parent\" which they are responding to (either posts or other comments)\r\n-make the _comment partial recursive, so that a comment displays all its replies just below it in a nested list","created_at":"2014-07-29T20:22:35Z","updated_at":"2014-07-30T14:29:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":"62e827128c0ec8d3f073ffe55e70f19e7ae6ba4e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/amZotti/wastr/pulls/7/commits","review_comments_url":"https://api.github.com/repos/amZotti/wastr/pulls/7/comments","review_comment_url":"https://api.github.com/repos/amZotti/wastr/pulls/comments/{number}","comments_url":"https://api.github.com/repos/amZotti/wastr/issues/7/comments","statuses_url":"https://api.github.com/repos/amZotti/wastr/statuses/e6ad65f02c4bea5609b11e5924ba2a2913f17874","head":{"label":"amZotti:gg-users-can-reply-to-comments","ref":"gg-users-can-reply-to-comments","sha":"e6ad65f02c4bea5609b11e5924ba2a2913f17874","user":{"login":"amZotti","id":5640348,"avatar_url":"https://avatars.githubusercontent.com/u/5640348?v=1","gravatar_id":"97d7a1c31dad9d8c2af6213a98813de9","url":"https://api.github.com/users/amZotti","html_url":"https://github.com/amZotti","followers_url":"https://api.github.com/users/amZotti/followers","following_url":"https://api.github.com/users/amZotti/following{/other_user}","gists_url":"https://api.github.com/users/amZotti/gists{/gist_id}","starred_url":"https://api.github.com/users/amZotti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amZotti/subscriptions","organizations_url":"https://api.github.com/users/amZotti/orgs","repos_url":"https://api.github.com/users/amZotti/repos","events_url":"https://api.github.com/users/amZotti/events{/privacy}","received_events_url":"https://api.github.com/users/amZotti/received_events","type":"User","site_admin":false},"repo":{"id":22344400,"name":"wastr","full_name":"amZotti/wastr","owner":{"login":"amZotti","id":5640348,"avatar_url":"https://avatars.githubusercontent.com/u/5640348?v=1","gravatar_id":"97d7a1c31dad9d8c2af6213a98813de9","url":"https://api.github.com/users/amZotti","html_url":"https://github.com/amZotti","followers_url":"https://api.github.com/users/amZotti/followers","following_url":"https://api.github.com/users/amZotti/following{/other_user}","gists_url":"https://api.github.com/users/amZotti/gists{/gist_id}","starred_url":"https://api.github.com/users/amZotti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amZotti/subscriptions","organizations_url":"https://api.github.com/users/amZotti/orgs","repos_url":"https://api.github.com/users/amZotti/repos","events_url":"https://api.github.com/users/amZotti/events{/privacy}","received_events_url":"https://api.github.com/users/amZotti/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/amZotti/wastr","description":"A Reddit clone.","fork":false,"url":"https://api.github.com/repos/amZotti/wastr","forks_url":"https://api.github.com/repos/amZotti/wastr/forks","keys_url":"https://api.github.com/repos/amZotti/wastr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/amZotti/wastr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/amZotti/wastr/teams","hooks_url":"https://api.github.com/repos/amZotti/wastr/hooks","issue_events_url":"https://api.github.com/repos/amZotti/wastr/issues/events{/number}","events_url":"https://api.github.com/repos/amZotti/wastr/events","assignees_url":"https://api.github.com/repos/amZotti/wastr/assignees{/user}","branches_url":"https://api.github.com/repos/amZotti/wastr/branches{/branch}","tags_url":"https://api.github.com/repos/amZotti/wastr/tags","blobs_url":"https://api.github.com/repos/amZotti/wastr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/amZotti/wastr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/amZotti/wastr/git/refs{/sha}","trees_url":"https://api.github.com/repos/amZotti/wastr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/amZotti/wastr/statuses/{sha}","languages_url":"https://api.github.com/repos/amZotti/wastr/languages","stargazers_url":"https://api.github.com/repos/amZotti/wastr/stargazers","contributors_url":"https://api.github.com/repos/amZotti/wastr/contributors","subscribers_url":"https://api.github.com/repos/amZotti/wastr/subscribers","subscription_url":"https://api.github.com/repos/amZotti/wastr/subscription","commits_url":"https://api.github.com/repos/amZotti/wastr/commits{/sha}","git_commits_url":"https://api.github.com/repos/amZotti/wastr/git/commits{/sha}","comments_url":"https://api.github.com/repos/amZotti/wastr/comments{/number}","issue_comment_url":"https://api.github.com/repos/amZotti/wastr/issues/comments/{number}","contents_url":"https://api.github.com/repos/amZotti/wastr/contents/{+path}","compare_url":"https://api.github.com/repos/amZotti/wastr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/amZotti/wastr/merges","archive_url":"https://api.github.com/repos/amZotti/wastr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/amZotti/wastr/downloads","issues_url":"https://api.github.com/repos/amZotti/wastr/issues{/number}","pulls_url":"https://api.github.com/repos/amZotti/wastr/pulls{/number}","milestones_url":"https://api.github.com/repos/amZotti/wastr/milestones{/number}","notifications_url":"https://api.github.com/repos/amZotti/wastr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/amZotti/wastr/labels{/name}","releases_url":"https://api.github.com/repos/amZotti/wastr/releases{/id}","created_at":"2014-07-28T13:58:52Z","updated_at":"2014-07-28T13:59:32Z","pushed_at":"2014-07-30T13:55:48Z","git_url":"git://github.com/amZotti/wastr.git","ssh_url":"git@github.com:amZotti/wastr.git","clone_url":"https://github.com/amZotti/wastr.git","svn_url":"https://github.com/amZotti/wastr","homepage":null,"size":588,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"amZotti:master","ref":"master","sha":"40062d8479756775c03e49ea6a6f4e0cf6f57b11","user":{"login":"amZotti","id":5640348,"avatar_url":"https://avatars.githubusercontent.com/u/5640348?v=1","gravatar_id":"97d7a1c31dad9d8c2af6213a98813de9","url":"https://api.github.com/users/amZotti","html_url":"https://github.com/amZotti","followers_url":"https://api.github.com/users/amZotti/followers","following_url":"https://api.github.com/users/amZotti/following{/other_user}","gists_url":"https://api.github.com/users/amZotti/gists{/gist_id}","starred_url":"https://api.github.com/users/amZotti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amZotti/subscriptions","organizations_url":"https://api.github.com/users/amZotti/orgs","repos_url":"https://api.github.com/users/amZotti/repos","events_url":"https://api.github.com/users/amZotti/events{/privacy}","received_events_url":"https://api.github.com/users/amZotti/received_events","type":"User","site_admin":false},"repo":{"id":22344400,"name":"wastr","full_name":"amZotti/wastr","owner":{"login":"amZotti","id":5640348,"avatar_url":"https://avatars.githubusercontent.com/u/5640348?v=1","gravatar_id":"97d7a1c31dad9d8c2af6213a98813de9","url":"https://api.github.com/users/amZotti","html_url":"https://github.com/amZotti","followers_url":"https://api.github.com/users/amZotti/followers","following_url":"https://api.github.com/users/amZotti/following{/other_user}","gists_url":"https://api.github.com/users/amZotti/gists{/gist_id}","starred_url":"https://api.github.com/users/amZotti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amZotti/subscriptions","organizations_url":"https://api.github.com/users/amZotti/orgs","repos_url":"https://api.github.com/users/amZotti/repos","events_url":"https://api.github.com/users/amZotti/events{/privacy}","received_events_url":"https://api.github.com/users/amZotti/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/amZotti/wastr","description":"A Reddit clone.","fork":false,"url":"https://api.github.com/repos/amZotti/wastr","forks_url":"https://api.github.com/repos/amZotti/wastr/forks","keys_url":"https://api.github.com/repos/amZotti/wastr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/amZotti/wastr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/amZotti/wastr/teams","hooks_url":"https://api.github.com/repos/amZotti/wastr/hooks","issue_events_url":"https://api.github.com/repos/amZotti/wastr/issues/events{/number}","events_url":"https://api.github.com/repos/amZotti/wastr/events","assignees_url":"https://api.github.com/repos/amZotti/wastr/assignees{/user}","branches_url":"https://api.github.com/repos/amZotti/wastr/branches{/branch}","tags_url":"https://api.github.com/repos/amZotti/wastr/tags","blobs_url":"https://api.github.com/repos/amZotti/wastr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/amZotti/wastr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/amZotti/wastr/git/refs{/sha}","trees_url":"https://api.github.com/repos/amZotti/wastr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/amZotti/wastr/statuses/{sha}","languages_url":"https://api.github.com/repos/amZotti/wastr/languages","stargazers_url":"https://api.github.com/repos/amZotti/wastr/stargazers","contributors_url":"https://api.github.com/repos/amZotti/wastr/contributors","subscribers_url":"https://api.github.com/repos/amZotti/wastr/subscribers","subscription_url":"https://api.github.com/repos/amZotti/wastr/subscription","commits_url":"https://api.github.com/repos/amZotti/wastr/commits{/sha}","git_commits_url":"https://api.github.com/repos/amZotti/wastr/git/commits{/sha}","comments_url":"https://api.github.com/repos/amZotti/wastr/comments{/number}","issue_comment_url":"https://api.github.com/repos/amZotti/wastr/issues/comments/{number}","contents_url":"https://api.github.com/repos/amZotti/wastr/contents/{+path}","compare_url":"https://api.github.com/repos/amZotti/wastr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/amZotti/wastr/merges","archive_url":"https://api.github.com/repos/amZotti/wastr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/amZotti/wastr/downloads","issues_url":"https://api.github.com/repos/amZotti/wastr/issues{/number}","pulls_url":"https://api.github.com/repos/amZotti/wastr/pulls{/number}","milestones_url":"https://api.github.com/repos/amZotti/wastr/milestones{/number}","notifications_url":"https://api.github.com/repos/amZotti/wastr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/amZotti/wastr/labels{/name}","releases_url":"https://api.github.com/repos/amZotti/wastr/releases{/id}","created_at":"2014-07-28T13:58:52Z","updated_at":"2014-07-28T13:59:32Z","pushed_at":"2014-07-30T13:55:48Z","git_url":"git://github.com/amZotti/wastr.git","ssh_url":"git@github.com:amZotti/wastr.git","clone_url":"https://github.com/amZotti/wastr.git","svn_url":"https://github.com/amZotti/wastr","homepage":null,"size":588,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"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/amZotti/wastr/pulls/7"},"html":{"href":"https://github.com/amZotti/wastr/pull/7"},"issue":{"href":"https://api.github.com/repos/amZotti/wastr/issues/7"},"comments":{"href":"https://api.github.com/repos/amZotti/wastr/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/amZotti/wastr/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/amZotti/wastr/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/amZotti/wastr/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/amZotti/wastr/statuses/e6ad65f02c4bea5609b11e5924ba2a2913f17874"}}}}