{"action":"created","comment":{"url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/comments/41427134","id":41427134,"diff_hunk":"@@ -0,0 +1,39 @@\n+class MoveVote < ActiveRecord::Base\n+  belongs_to :move\n+  belongs_to :user\n+\n+  validates :user, uniqueness: { scope: :move }\n+  validates :upvote, presence: true\n+  validates :downvote, presence: true\n+  validates :upvote, numericality: { only_integer: true }\n+  validates :downvote, numericality: { only_integer: true }\n+  # between 1 and 0\n+\n+  def destroy_if_exists(vote_type)\n+    if vote_type == \"upvote\"\n+      if self.upvote == 1\n+        self.destroy","path":"app/models/move_vote.rb","position":15,"original_position":15,"commit_id":"68c7604690ab662177cc21bbd5d219ce2d185ce1","original_commit_id":"68c7604690ab662177cc21bbd5d219ce2d185ce1","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":"Redundant `self` detected.","created_at":"2015-10-07T18:28:47Z","updated_at":"2015-10-07T18:28:47Z","html_url":"https://github.com/philiptang42/MKX-Frame-Data/pull/11#discussion_r41427134","pull_request_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11","_links":{"self":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/comments/41427134"},"html":{"href":"https://github.com/philiptang42/MKX-Frame-Data/pull/11#discussion_r41427134"},"pull_request":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11"}}},"pull_request":{"url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11","id":47063894,"html_url":"https://github.com/philiptang42/MKX-Frame-Data/pull/11","diff_url":"https://github.com/philiptang42/MKX-Frame-Data/pull/11.diff","patch_url":"https://github.com/philiptang42/MKX-Frame-Data/pull/11.patch","issue_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/11","number":11,"state":"open","locked":false,"title":"Added all required models and tests for them","user":{"login":"philiptang42","id":12959491,"avatar_url":"https://avatars.githubusercontent.com/u/12959491?v=3","gravatar_id":"","url":"https://api.github.com/users/philiptang42","html_url":"https://github.com/philiptang42","followers_url":"https://api.github.com/users/philiptang42/followers","following_url":"https://api.github.com/users/philiptang42/following{/other_user}","gists_url":"https://api.github.com/users/philiptang42/gists{/gist_id}","starred_url":"https://api.github.com/users/philiptang42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philiptang42/subscriptions","organizations_url":"https://api.github.com/users/philiptang42/orgs","repos_url":"https://api.github.com/users/philiptang42/repos","events_url":"https://api.github.com/users/philiptang42/events{/privacy}","received_events_url":"https://api.github.com/users/philiptang42/received_events","type":"User","site_admin":false},"body":"I ended up adding more than just characters and moves. ALL THE MODELS","created_at":"2015-10-07T18:28:39Z","updated_at":"2015-10-07T18:28:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8430628e566fc979b4d780abd27002fa1a0a5e0b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11/commits","review_comments_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11/comments","review_comment_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/comments{/number}","comments_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/11/comments","statuses_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/statuses/68c7604690ab662177cc21bbd5d219ce2d185ce1","head":{"label":"philiptang42:model-validations-char-and-moves","ref":"model-validations-char-and-moves","sha":"68c7604690ab662177cc21bbd5d219ce2d185ce1","user":{"login":"philiptang42","id":12959491,"avatar_url":"https://avatars.githubusercontent.com/u/12959491?v=3","gravatar_id":"","url":"https://api.github.com/users/philiptang42","html_url":"https://github.com/philiptang42","followers_url":"https://api.github.com/users/philiptang42/followers","following_url":"https://api.github.com/users/philiptang42/following{/other_user}","gists_url":"https://api.github.com/users/philiptang42/gists{/gist_id}","starred_url":"https://api.github.com/users/philiptang42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philiptang42/subscriptions","organizations_url":"https://api.github.com/users/philiptang42/orgs","repos_url":"https://api.github.com/users/philiptang42/repos","events_url":"https://api.github.com/users/philiptang42/events{/privacy}","received_events_url":"https://api.github.com/users/philiptang42/received_events","type":"User","site_admin":false},"repo":{"id":43696331,"name":"MKX-Frame-Data","full_name":"philiptang42/MKX-Frame-Data","owner":{"login":"philiptang42","id":12959491,"avatar_url":"https://avatars.githubusercontent.com/u/12959491?v=3","gravatar_id":"","url":"https://api.github.com/users/philiptang42","html_url":"https://github.com/philiptang42","followers_url":"https://api.github.com/users/philiptang42/followers","following_url":"https://api.github.com/users/philiptang42/following{/other_user}","gists_url":"https://api.github.com/users/philiptang42/gists{/gist_id}","starred_url":"https://api.github.com/users/philiptang42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philiptang42/subscriptions","organizations_url":"https://api.github.com/users/philiptang42/orgs","repos_url":"https://api.github.com/users/philiptang42/repos","events_url":"https://api.github.com/users/philiptang42/events{/privacy}","received_events_url":"https://api.github.com/users/philiptang42/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/philiptang42/MKX-Frame-Data","description":"","fork":false,"url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data","forks_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/forks","keys_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/keys{/key_id}","collaborators_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/teams","hooks_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/hooks","issue_events_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/events{/number}","events_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/events","assignees_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/assignees{/user}","branches_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/branches{/branch}","tags_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/tags","blobs_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/refs{/sha}","trees_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/trees{/sha}","statuses_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/statuses/{sha}","languages_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/languages","stargazers_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/stargazers","contributors_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/contributors","subscribers_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/subscribers","subscription_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/subscription","commits_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/commits{/sha}","git_commits_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/commits{/sha}","comments_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/comments{/number}","issue_comment_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/comments{/number}","contents_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/contents/{+path}","compare_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/compare/{base}...{head}","merges_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/merges","archive_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/downloads","issues_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues{/number}","pulls_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls{/number}","milestones_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/milestones{/number}","notifications_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/labels{/name}","releases_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/releases{/id}","created_at":"2015-10-05T15:58:27Z","updated_at":"2015-10-05T15:59:49Z","pushed_at":"2015-10-07T18:28:39Z","git_url":"git://github.com/philiptang42/MKX-Frame-Data.git","ssh_url":"git@github.com:philiptang42/MKX-Frame-Data.git","clone_url":"https://github.com/philiptang42/MKX-Frame-Data.git","svn_url":"https://github.com/philiptang42/MKX-Frame-Data","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"CSS","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":"philiptang42:master","ref":"master","sha":"f581d2b0683aa30f786c321db343641e3b38bc8d","user":{"login":"philiptang42","id":12959491,"avatar_url":"https://avatars.githubusercontent.com/u/12959491?v=3","gravatar_id":"","url":"https://api.github.com/users/philiptang42","html_url":"https://github.com/philiptang42","followers_url":"https://api.github.com/users/philiptang42/followers","following_url":"https://api.github.com/users/philiptang42/following{/other_user}","gists_url":"https://api.github.com/users/philiptang42/gists{/gist_id}","starred_url":"https://api.github.com/users/philiptang42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philiptang42/subscriptions","organizations_url":"https://api.github.com/users/philiptang42/orgs","repos_url":"https://api.github.com/users/philiptang42/repos","events_url":"https://api.github.com/users/philiptang42/events{/privacy}","received_events_url":"https://api.github.com/users/philiptang42/received_events","type":"User","site_admin":false},"repo":{"id":43696331,"name":"MKX-Frame-Data","full_name":"philiptang42/MKX-Frame-Data","owner":{"login":"philiptang42","id":12959491,"avatar_url":"https://avatars.githubusercontent.com/u/12959491?v=3","gravatar_id":"","url":"https://api.github.com/users/philiptang42","html_url":"https://github.com/philiptang42","followers_url":"https://api.github.com/users/philiptang42/followers","following_url":"https://api.github.com/users/philiptang42/following{/other_user}","gists_url":"https://api.github.com/users/philiptang42/gists{/gist_id}","starred_url":"https://api.github.com/users/philiptang42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philiptang42/subscriptions","organizations_url":"https://api.github.com/users/philiptang42/orgs","repos_url":"https://api.github.com/users/philiptang42/repos","events_url":"https://api.github.com/users/philiptang42/events{/privacy}","received_events_url":"https://api.github.com/users/philiptang42/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/philiptang42/MKX-Frame-Data","description":"","fork":false,"url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data","forks_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/forks","keys_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/keys{/key_id}","collaborators_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/teams","hooks_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/hooks","issue_events_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/events{/number}","events_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/events","assignees_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/assignees{/user}","branches_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/branches{/branch}","tags_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/tags","blobs_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/refs{/sha}","trees_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/trees{/sha}","statuses_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/statuses/{sha}","languages_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/languages","stargazers_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/stargazers","contributors_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/contributors","subscribers_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/subscribers","subscription_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/subscription","commits_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/commits{/sha}","git_commits_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/git/commits{/sha}","comments_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/comments{/number}","issue_comment_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/comments{/number}","contents_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/contents/{+path}","compare_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/compare/{base}...{head}","merges_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/merges","archive_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/downloads","issues_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues{/number}","pulls_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls{/number}","milestones_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/milestones{/number}","notifications_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/labels{/name}","releases_url":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/releases{/id}","created_at":"2015-10-05T15:58:27Z","updated_at":"2015-10-05T15:59:49Z","pushed_at":"2015-10-07T18:28:39Z","git_url":"git://github.com/philiptang42/MKX-Frame-Data.git","ssh_url":"git@github.com:philiptang42/MKX-Frame-Data.git","clone_url":"https://github.com/philiptang42/MKX-Frame-Data.git","svn_url":"https://github.com/philiptang42/MKX-Frame-Data","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"CSS","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/philiptang42/MKX-Frame-Data/pulls/11"},"html":{"href":"https://github.com/philiptang42/MKX-Frame-Data/pull/11"},"issue":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/11"},"comments":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/philiptang42/MKX-Frame-Data/statuses/68c7604690ab662177cc21bbd5d219ce2d185ce1"}}}}