{"action":"created","comment":{"url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/comments/59145858","id":59145858,"diff_hunk":"@@ -1079,4 +1079,16 @@ CREATE OR REPLACE FUNCTION track_count_matches_cdtoc(medium, int) RETURNS boolea\n $$ LANGUAGE SQL IMMUTABLE;\n \n COMMIT;\n+\n+-----------------------------------------------------------------------\n+-- edit_note triggers\n+-----------------------------------------------------------------------\n+\n+CREATE OR REPLACE FUNCTION a_insert_edit_note() RETURNS trigger AS $$\n+BEGIN\n+    INSERT INTO edit_note_recipient (editor_id, edit_note_id) VALUES (NEW.editor, NEW.id);","path":"admin/sql/CreateFunctions.sql","position":11,"original_position":11,"commit_id":"3422dd747bc609260a886a07f2bc30b8eb5d5a02","original_commit_id":"3422dd747bc609260a886a07f2bc30b8eb5d5a02","user":{"login":"mwiencek","id":1056556,"avatar_url":"https://avatars.githubusercontent.com/u/1056556?v=3","gravatar_id":"","url":"https://api.github.com/users/mwiencek","html_url":"https://github.com/mwiencek","followers_url":"https://api.github.com/users/mwiencek/followers","following_url":"https://api.github.com/users/mwiencek/following{/other_user}","gists_url":"https://api.github.com/users/mwiencek/gists{/gist_id}","starred_url":"https://api.github.com/users/mwiencek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mwiencek/subscriptions","organizations_url":"https://api.github.com/users/mwiencek/orgs","repos_url":"https://api.github.com/users/mwiencek/repos","events_url":"https://api.github.com/users/mwiencek/events{/privacy}","received_events_url":"https://api.github.com/users/mwiencek/received_events","type":"User","site_admin":false},"body":"`NEW.editor` is the person who left the note, so that actually needs to get the edit author from the `edit` table (join on `NEW.edit = edit.id`).","created_at":"2016-04-11T01:00:20Z","updated_at":"2016-04-11T01:00:20Z","html_url":"https://github.com/metabrainz/musicbrainz-server/pull/271#discussion_r59145858","pull_request_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271","_links":{"self":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/comments/59145858"},"html":{"href":"https://github.com/metabrainz/musicbrainz-server/pull/271#discussion_r59145858"},"pull_request":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271"}}},"pull_request":{"url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271","id":65928138,"html_url":"https://github.com/metabrainz/musicbrainz-server/pull/271","diff_url":"https://github.com/metabrainz/musicbrainz-server/pull/271.diff","patch_url":"https://github.com/metabrainz/musicbrainz-server/pull/271.patch","issue_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/271","number":271,"state":"open","locked":false,"title":"MBS-8720: Materialized view of edit note recipients","user":{"login":"gentlecat","id":460525,"avatar_url":"https://avatars.githubusercontent.com/u/460525?v=3","gravatar_id":"","url":"https://api.github.com/users/gentlecat","html_url":"https://github.com/gentlecat","followers_url":"https://api.github.com/users/gentlecat/followers","following_url":"https://api.github.com/users/gentlecat/following{/other_user}","gists_url":"https://api.github.com/users/gentlecat/gists{/gist_id}","starred_url":"https://api.github.com/users/gentlecat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gentlecat/subscriptions","organizations_url":"https://api.github.com/users/gentlecat/orgs","repos_url":"https://api.github.com/users/gentlecat/repos","events_url":"https://api.github.com/users/gentlecat/events{/privacy}","received_events_url":"https://api.github.com/users/gentlecat/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-04-11T00:08:42Z","updated_at":"2016-04-11T01:00:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c13d1dc37629083a7b6bdf9adb0371db80f86dc2","assignee":{"login":"mwiencek","id":1056556,"avatar_url":"https://avatars.githubusercontent.com/u/1056556?v=3","gravatar_id":"","url":"https://api.github.com/users/mwiencek","html_url":"https://github.com/mwiencek","followers_url":"https://api.github.com/users/mwiencek/followers","following_url":"https://api.github.com/users/mwiencek/following{/other_user}","gists_url":"https://api.github.com/users/mwiencek/gists{/gist_id}","starred_url":"https://api.github.com/users/mwiencek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mwiencek/subscriptions","organizations_url":"https://api.github.com/users/mwiencek/orgs","repos_url":"https://api.github.com/users/mwiencek/repos","events_url":"https://api.github.com/users/mwiencek/events{/privacy}","received_events_url":"https://api.github.com/users/mwiencek/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271/commits","review_comments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271/comments","review_comment_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/comments{/number}","comments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/271/comments","statuses_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/statuses/3422dd747bc609260a886a07f2bc30b8eb5d5a02","head":{"label":"metabrainz:mbs-8720","ref":"mbs-8720","sha":"3422dd747bc609260a886a07f2bc30b8eb5d5a02","user":{"login":"metabrainz","id":293421,"avatar_url":"https://avatars.githubusercontent.com/u/293421?v=3","gravatar_id":"","url":"https://api.github.com/users/metabrainz","html_url":"https://github.com/metabrainz","followers_url":"https://api.github.com/users/metabrainz/followers","following_url":"https://api.github.com/users/metabrainz/following{/other_user}","gists_url":"https://api.github.com/users/metabrainz/gists{/gist_id}","starred_url":"https://api.github.com/users/metabrainz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metabrainz/subscriptions","organizations_url":"https://api.github.com/users/metabrainz/orgs","repos_url":"https://api.github.com/users/metabrainz/repos","events_url":"https://api.github.com/users/metabrainz/events{/privacy}","received_events_url":"https://api.github.com/users/metabrainz/received_events","type":"Organization","site_admin":false},"repo":{"id":697520,"name":"musicbrainz-server","full_name":"metabrainz/musicbrainz-server","owner":{"login":"metabrainz","id":293421,"avatar_url":"https://avatars.githubusercontent.com/u/293421?v=3","gravatar_id":"","url":"https://api.github.com/users/metabrainz","html_url":"https://github.com/metabrainz","followers_url":"https://api.github.com/users/metabrainz/followers","following_url":"https://api.github.com/users/metabrainz/following{/other_user}","gists_url":"https://api.github.com/users/metabrainz/gists{/gist_id}","starred_url":"https://api.github.com/users/metabrainz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metabrainz/subscriptions","organizations_url":"https://api.github.com/users/metabrainz/orgs","repos_url":"https://api.github.com/users/metabrainz/repos","events_url":"https://api.github.com/users/metabrainz/events{/privacy}","received_events_url":"https://api.github.com/users/metabrainz/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/metabrainz/musicbrainz-server","description":"The official musicbrainz-server codebase","fork":false,"url":"https://api.github.com/repos/metabrainz/musicbrainz-server","forks_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/forks","keys_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/teams","hooks_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/hooks","issue_events_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/events{/number}","events_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/events","assignees_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/assignees{/user}","branches_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/branches{/branch}","tags_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/tags","blobs_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/statuses/{sha}","languages_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/languages","stargazers_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/stargazers","contributors_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/contributors","subscribers_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/subscribers","subscription_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/subscription","commits_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/contents/{+path}","compare_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/merges","archive_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/downloads","issues_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues{/number}","pulls_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls{/number}","milestones_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/milestones{/number}","notifications_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/labels{/name}","releases_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/releases{/id}","deployments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/deployments","created_at":"2010-06-01T16:30:04Z","updated_at":"2016-04-09T16:38:57Z","pushed_at":"2016-04-11T00:27:51Z","git_url":"git://github.com/metabrainz/musicbrainz-server.git","ssh_url":"git@github.com:metabrainz/musicbrainz-server.git","clone_url":"https://github.com/metabrainz/musicbrainz-server.git","svn_url":"https://github.com/metabrainz/musicbrainz-server","homepage":"http://musicbrainz.org/doc/MusicBrainz_Server","size":91726,"stargazers_count":235,"watchers_count":235,"language":"Perl","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":100,"mirror_url":null,"open_issues_count":4,"forks":100,"open_issues":4,"watchers":235,"default_branch":"master"}},"base":{"label":"metabrainz:schema-change-2016-q2","ref":"schema-change-2016-q2","sha":"e37ce6d9541aeb5e1a4c90310c2f028d3a8ca2c6","user":{"login":"metabrainz","id":293421,"avatar_url":"https://avatars.githubusercontent.com/u/293421?v=3","gravatar_id":"","url":"https://api.github.com/users/metabrainz","html_url":"https://github.com/metabrainz","followers_url":"https://api.github.com/users/metabrainz/followers","following_url":"https://api.github.com/users/metabrainz/following{/other_user}","gists_url":"https://api.github.com/users/metabrainz/gists{/gist_id}","starred_url":"https://api.github.com/users/metabrainz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metabrainz/subscriptions","organizations_url":"https://api.github.com/users/metabrainz/orgs","repos_url":"https://api.github.com/users/metabrainz/repos","events_url":"https://api.github.com/users/metabrainz/events{/privacy}","received_events_url":"https://api.github.com/users/metabrainz/received_events","type":"Organization","site_admin":false},"repo":{"id":697520,"name":"musicbrainz-server","full_name":"metabrainz/musicbrainz-server","owner":{"login":"metabrainz","id":293421,"avatar_url":"https://avatars.githubusercontent.com/u/293421?v=3","gravatar_id":"","url":"https://api.github.com/users/metabrainz","html_url":"https://github.com/metabrainz","followers_url":"https://api.github.com/users/metabrainz/followers","following_url":"https://api.github.com/users/metabrainz/following{/other_user}","gists_url":"https://api.github.com/users/metabrainz/gists{/gist_id}","starred_url":"https://api.github.com/users/metabrainz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metabrainz/subscriptions","organizations_url":"https://api.github.com/users/metabrainz/orgs","repos_url":"https://api.github.com/users/metabrainz/repos","events_url":"https://api.github.com/users/metabrainz/events{/privacy}","received_events_url":"https://api.github.com/users/metabrainz/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/metabrainz/musicbrainz-server","description":"The official musicbrainz-server codebase","fork":false,"url":"https://api.github.com/repos/metabrainz/musicbrainz-server","forks_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/forks","keys_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/teams","hooks_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/hooks","issue_events_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/events{/number}","events_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/events","assignees_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/assignees{/user}","branches_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/branches{/branch}","tags_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/tags","blobs_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/statuses/{sha}","languages_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/languages","stargazers_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/stargazers","contributors_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/contributors","subscribers_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/subscribers","subscription_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/subscription","commits_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/contents/{+path}","compare_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/merges","archive_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/downloads","issues_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues{/number}","pulls_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls{/number}","milestones_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/milestones{/number}","notifications_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/labels{/name}","releases_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/releases{/id}","deployments_url":"https://api.github.com/repos/metabrainz/musicbrainz-server/deployments","created_at":"2010-06-01T16:30:04Z","updated_at":"2016-04-09T16:38:57Z","pushed_at":"2016-04-11T00:27:51Z","git_url":"git://github.com/metabrainz/musicbrainz-server.git","ssh_url":"git@github.com:metabrainz/musicbrainz-server.git","clone_url":"https://github.com/metabrainz/musicbrainz-server.git","svn_url":"https://github.com/metabrainz/musicbrainz-server","homepage":"http://musicbrainz.org/doc/MusicBrainz_Server","size":91726,"stargazers_count":235,"watchers_count":235,"language":"Perl","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":100,"mirror_url":null,"open_issues_count":4,"forks":100,"open_issues":4,"watchers":235,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271"},"html":{"href":"https://github.com/metabrainz/musicbrainz-server/pull/271"},"issue":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/271"},"comments":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/issues/271/comments"},"review_comments":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271/comments"},"review_comment":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/pulls/271/commits"},"statuses":{"href":"https://api.github.com/repos/metabrainz/musicbrainz-server/statuses/3422dd747bc609260a886a07f2bc30b8eb5d5a02"}}}}