{"action":"created","comment":{"url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/64049685","id":64049685,"diff_hunk":"@@ -914,6 +915,28 @@ def has_peer_review_assignment?\n     not pr_assignment.nil?\n   end\n \n+  def create_peer_review_assignment_if_not_exist\n+    if has_peer_review and Assignment.where(parent_assignment_id: id).empty?\n+      peerreview_assignment = Assignment.new\n+      peerreview_assignment.parent_assignment = self\n+      peerreview_assignment.submission_rule = NoLateSubmissionRule.new\n+      peerreview_assignment.assignment_stat = AssignmentStat.new\n+      peerreview_assignment.token_period = 1\n+      peerreview_assignment.unlimited_tokens = false\n+      peerreview_assignment.short_identifier = short_identifier + '_pr'\n+      peerreview_assignment.description = ''","path":"app/models/assignment.rb","position":21,"original_position":21,"commit_id":"5333aa29d968011ba3a0bfac4e005dfc3a5aef2c","original_commit_id":"5333aa29d968011ba3a0bfac4e005dfc3a5aef2c","user":{"login":"WChrisK","id":3758824,"avatar_url":"https://avatars.githubusercontent.com/u/3758824?v=3","gravatar_id":"","url":"https://api.github.com/users/WChrisK","html_url":"https://github.com/WChrisK","followers_url":"https://api.github.com/users/WChrisK/followers","following_url":"https://api.github.com/users/WChrisK/following{/other_user}","gists_url":"https://api.github.com/users/WChrisK/gists{/gist_id}","starred_url":"https://api.github.com/users/WChrisK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WChrisK/subscriptions","organizations_url":"https://api.github.com/users/WChrisK/orgs","repos_url":"https://api.github.com/users/WChrisK/repos","events_url":"https://api.github.com/users/WChrisK/events{/privacy}","received_events_url":"https://api.github.com/users/WChrisK/received_events","type":"User","site_admin":false},"body":"Is this what you meant by leaving it blank? (or use `nil`? or something else?)","created_at":"2016-05-20T14:28:22Z","updated_at":"2016-05-20T14:28:22Z","html_url":"https://github.com/MarkUsProject/Markus/pull/2590#discussion_r64049685","pull_request_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590","_links":{"self":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/64049685"},"html":{"href":"https://github.com/MarkUsProject/Markus/pull/2590#discussion_r64049685"},"pull_request":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590"}}},"pull_request":{"url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590","id":70770440,"html_url":"https://github.com/MarkUsProject/Markus/pull/2590","diff_url":"https://github.com/MarkUsProject/Markus/pull/2590.diff","patch_url":"https://github.com/MarkUsProject/Markus/pull/2590.patch","issue_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/2590","number":2590,"state":"open","locked":false,"title":"Assignment tab","user":{"login":"WChrisK","id":3758824,"avatar_url":"https://avatars.githubusercontent.com/u/3758824?v=3","gravatar_id":"","url":"https://api.github.com/users/WChrisK","html_url":"https://github.com/WChrisK","followers_url":"https://api.github.com/users/WChrisK/followers","following_url":"https://api.github.com/users/WChrisK/following{/other_user}","gists_url":"https://api.github.com/users/WChrisK/gists{/gist_id}","starred_url":"https://api.github.com/users/WChrisK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WChrisK/subscriptions","organizations_url":"https://api.github.com/users/WChrisK/orgs","repos_url":"https://api.github.com/users/WChrisK/repos","events_url":"https://api.github.com/users/WChrisK/events{/privacy}","received_events_url":"https://api.github.com/users/WChrisK/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-05-19T21:43:26Z","updated_at":"2016-05-20T14:28:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5c015c3dd08432224fbee6687642cd70df868768","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590/commits","review_comments_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590/comments","review_comment_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments{/number}","comments_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/2590/comments","statuses_url":"https://api.github.com/repos/MarkUsProject/Markus/statuses/5333aa29d968011ba3a0bfac4e005dfc3a5aef2c","head":{"label":"WChrisK:assignment_tab","ref":"assignment_tab","sha":"5333aa29d968011ba3a0bfac4e005dfc3a5aef2c","user":{"login":"WChrisK","id":3758824,"avatar_url":"https://avatars.githubusercontent.com/u/3758824?v=3","gravatar_id":"","url":"https://api.github.com/users/WChrisK","html_url":"https://github.com/WChrisK","followers_url":"https://api.github.com/users/WChrisK/followers","following_url":"https://api.github.com/users/WChrisK/following{/other_user}","gists_url":"https://api.github.com/users/WChrisK/gists{/gist_id}","starred_url":"https://api.github.com/users/WChrisK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WChrisK/subscriptions","organizations_url":"https://api.github.com/users/WChrisK/orgs","repos_url":"https://api.github.com/users/WChrisK/repos","events_url":"https://api.github.com/users/WChrisK/events{/privacy}","received_events_url":"https://api.github.com/users/WChrisK/received_events","type":"User","site_admin":false},"repo":{"id":57914865,"name":"Markus","full_name":"WChrisK/Markus","owner":{"login":"WChrisK","id":3758824,"avatar_url":"https://avatars.githubusercontent.com/u/3758824?v=3","gravatar_id":"","url":"https://api.github.com/users/WChrisK","html_url":"https://github.com/WChrisK","followers_url":"https://api.github.com/users/WChrisK/followers","following_url":"https://api.github.com/users/WChrisK/following{/other_user}","gists_url":"https://api.github.com/users/WChrisK/gists{/gist_id}","starred_url":"https://api.github.com/users/WChrisK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WChrisK/subscriptions","organizations_url":"https://api.github.com/users/WChrisK/orgs","repos_url":"https://api.github.com/users/WChrisK/repos","events_url":"https://api.github.com/users/WChrisK/events{/privacy}","received_events_url":"https://api.github.com/users/WChrisK/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/WChrisK/Markus","description":"Git repository of MarkUs","fork":true,"url":"https://api.github.com/repos/WChrisK/Markus","forks_url":"https://api.github.com/repos/WChrisK/Markus/forks","keys_url":"https://api.github.com/repos/WChrisK/Markus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WChrisK/Markus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WChrisK/Markus/teams","hooks_url":"https://api.github.com/repos/WChrisK/Markus/hooks","issue_events_url":"https://api.github.com/repos/WChrisK/Markus/issues/events{/number}","events_url":"https://api.github.com/repos/WChrisK/Markus/events","assignees_url":"https://api.github.com/repos/WChrisK/Markus/assignees{/user}","branches_url":"https://api.github.com/repos/WChrisK/Markus/branches{/branch}","tags_url":"https://api.github.com/repos/WChrisK/Markus/tags","blobs_url":"https://api.github.com/repos/WChrisK/Markus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WChrisK/Markus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WChrisK/Markus/git/refs{/sha}","trees_url":"https://api.github.com/repos/WChrisK/Markus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WChrisK/Markus/statuses/{sha}","languages_url":"https://api.github.com/repos/WChrisK/Markus/languages","stargazers_url":"https://api.github.com/repos/WChrisK/Markus/stargazers","contributors_url":"https://api.github.com/repos/WChrisK/Markus/contributors","subscribers_url":"https://api.github.com/repos/WChrisK/Markus/subscribers","subscription_url":"https://api.github.com/repos/WChrisK/Markus/subscription","commits_url":"https://api.github.com/repos/WChrisK/Markus/commits{/sha}","git_commits_url":"https://api.github.com/repos/WChrisK/Markus/git/commits{/sha}","comments_url":"https://api.github.com/repos/WChrisK/Markus/comments{/number}","issue_comment_url":"https://api.github.com/repos/WChrisK/Markus/issues/comments{/number}","contents_url":"https://api.github.com/repos/WChrisK/Markus/contents/{+path}","compare_url":"https://api.github.com/repos/WChrisK/Markus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WChrisK/Markus/merges","archive_url":"https://api.github.com/repos/WChrisK/Markus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WChrisK/Markus/downloads","issues_url":"https://api.github.com/repos/WChrisK/Markus/issues{/number}","pulls_url":"https://api.github.com/repos/WChrisK/Markus/pulls{/number}","milestones_url":"https://api.github.com/repos/WChrisK/Markus/milestones{/number}","notifications_url":"https://api.github.com/repos/WChrisK/Markus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WChrisK/Markus/labels{/name}","releases_url":"https://api.github.com/repos/WChrisK/Markus/releases{/id}","deployments_url":"https://api.github.com/repos/WChrisK/Markus/deployments","created_at":"2016-05-02T19:17:47Z","updated_at":"2016-05-02T19:17:51Z","pushed_at":"2016-05-20T14:25:56Z","git_url":"git://github.com/WChrisK/Markus.git","ssh_url":"git@github.com:WChrisK/Markus.git","clone_url":"https://github.com/WChrisK/Markus.git","svn_url":"https://github.com/WChrisK/Markus","homepage":"http://www.markusproject.org","size":26229,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"MarkUsProject:master","ref":"master","sha":"f0e4968e47f1c7037fbd3b355aefcea47d7230ab","user":{"login":"MarkUsProject","id":415874,"avatar_url":"https://avatars.githubusercontent.com/u/415874?v=3","gravatar_id":"","url":"https://api.github.com/users/MarkUsProject","html_url":"https://github.com/MarkUsProject","followers_url":"https://api.github.com/users/MarkUsProject/followers","following_url":"https://api.github.com/users/MarkUsProject/following{/other_user}","gists_url":"https://api.github.com/users/MarkUsProject/gists{/gist_id}","starred_url":"https://api.github.com/users/MarkUsProject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarkUsProject/subscriptions","organizations_url":"https://api.github.com/users/MarkUsProject/orgs","repos_url":"https://api.github.com/users/MarkUsProject/repos","events_url":"https://api.github.com/users/MarkUsProject/events{/privacy}","received_events_url":"https://api.github.com/users/MarkUsProject/received_events","type":"Organization","site_admin":false},"repo":{"id":940538,"name":"Markus","full_name":"MarkUsProject/Markus","owner":{"login":"MarkUsProject","id":415874,"avatar_url":"https://avatars.githubusercontent.com/u/415874?v=3","gravatar_id":"","url":"https://api.github.com/users/MarkUsProject","html_url":"https://github.com/MarkUsProject","followers_url":"https://api.github.com/users/MarkUsProject/followers","following_url":"https://api.github.com/users/MarkUsProject/following{/other_user}","gists_url":"https://api.github.com/users/MarkUsProject/gists{/gist_id}","starred_url":"https://api.github.com/users/MarkUsProject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarkUsProject/subscriptions","organizations_url":"https://api.github.com/users/MarkUsProject/orgs","repos_url":"https://api.github.com/users/MarkUsProject/repos","events_url":"https://api.github.com/users/MarkUsProject/events{/privacy}","received_events_url":"https://api.github.com/users/MarkUsProject/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MarkUsProject/Markus","description":"Git repository of MarkUs","fork":false,"url":"https://api.github.com/repos/MarkUsProject/Markus","forks_url":"https://api.github.com/repos/MarkUsProject/Markus/forks","keys_url":"https://api.github.com/repos/MarkUsProject/Markus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MarkUsProject/Markus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MarkUsProject/Markus/teams","hooks_url":"https://api.github.com/repos/MarkUsProject/Markus/hooks","issue_events_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/events{/number}","events_url":"https://api.github.com/repos/MarkUsProject/Markus/events","assignees_url":"https://api.github.com/repos/MarkUsProject/Markus/assignees{/user}","branches_url":"https://api.github.com/repos/MarkUsProject/Markus/branches{/branch}","tags_url":"https://api.github.com/repos/MarkUsProject/Markus/tags","blobs_url":"https://api.github.com/repos/MarkUsProject/Markus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MarkUsProject/Markus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MarkUsProject/Markus/git/refs{/sha}","trees_url":"https://api.github.com/repos/MarkUsProject/Markus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MarkUsProject/Markus/statuses/{sha}","languages_url":"https://api.github.com/repos/MarkUsProject/Markus/languages","stargazers_url":"https://api.github.com/repos/MarkUsProject/Markus/stargazers","contributors_url":"https://api.github.com/repos/MarkUsProject/Markus/contributors","subscribers_url":"https://api.github.com/repos/MarkUsProject/Markus/subscribers","subscription_url":"https://api.github.com/repos/MarkUsProject/Markus/subscription","commits_url":"https://api.github.com/repos/MarkUsProject/Markus/commits{/sha}","git_commits_url":"https://api.github.com/repos/MarkUsProject/Markus/git/commits{/sha}","comments_url":"https://api.github.com/repos/MarkUsProject/Markus/comments{/number}","issue_comment_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/comments{/number}","contents_url":"https://api.github.com/repos/MarkUsProject/Markus/contents/{+path}","compare_url":"https://api.github.com/repos/MarkUsProject/Markus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MarkUsProject/Markus/merges","archive_url":"https://api.github.com/repos/MarkUsProject/Markus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MarkUsProject/Markus/downloads","issues_url":"https://api.github.com/repos/MarkUsProject/Markus/issues{/number}","pulls_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls{/number}","milestones_url":"https://api.github.com/repos/MarkUsProject/Markus/milestones{/number}","notifications_url":"https://api.github.com/repos/MarkUsProject/Markus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MarkUsProject/Markus/labels{/name}","releases_url":"https://api.github.com/repos/MarkUsProject/Markus/releases{/id}","deployments_url":"https://api.github.com/repos/MarkUsProject/Markus/deployments","created_at":"2010-09-26T16:18:08Z","updated_at":"2016-04-04T13:51:17Z","pushed_at":"2016-05-20T14:25:57Z","git_url":"git://github.com/MarkUsProject/Markus.git","ssh_url":"git@github.com:MarkUsProject/Markus.git","clone_url":"https://github.com/MarkUsProject/Markus.git","svn_url":"https://github.com/MarkUsProject/Markus","homepage":"http://www.markusproject.org","size":37156,"stargazers_count":137,"watchers_count":137,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":172,"mirror_url":null,"open_issues_count":91,"forks":172,"open_issues":91,"watchers":137,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590"},"html":{"href":"https://github.com/MarkUsProject/Markus/pull/2590"},"issue":{"href":"https://api.github.com/repos/MarkUsProject/Markus/issues/2590"},"comments":{"href":"https://api.github.com/repos/MarkUsProject/Markus/issues/2590/comments"},"review_comments":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590/comments"},"review_comment":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/2590/commits"},"statuses":{"href":"https://api.github.com/repos/MarkUsProject/Markus/statuses/5333aa29d968011ba3a0bfac4e005dfc3a5aef2c"}}}}
{"actor":{"display_login":"WChrisK"}}