{"action":"created","comment":{"url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments/25515929","id":25515929,"diff_hunk":"@@ -0,0 +1,46 @@\n+CREATE OR REPLACE FUNCTION upsert_community() RETURNS trigger AS $$","path":"sql/upsert_community.sql","position":1,"original_position":1,"commit_id":"755716d1aeae91666fc499ec479dcd26f59de168","original_commit_id":"755716d1aeae91666fc499ec479dcd26f59de168","user":{"login":"whit537","id":134455,"avatar_url":"https://avatars.githubusercontent.com/u/134455?v=3","gravatar_id":"","url":"https://api.github.com/users/whit537","html_url":"https://github.com/whit537","followers_url":"https://api.github.com/users/whit537/followers","following_url":"https://api.github.com/users/whit537/following{/other_user}","gists_url":"https://api.github.com/users/whit537/gists{/gist_id}","starred_url":"https://api.github.com/users/whit537/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/whit537/subscriptions","organizations_url":"https://api.github.com/users/whit537/orgs","repos_url":"https://api.github.com/users/whit537/repos","events_url":"https://api.github.com/users/whit537/events{/privacy}","received_events_url":"https://api.github.com/users/whit537/received_events","type":"User","site_admin":false},"body":"Why do we use `CREATE OR REPLACE` here but just `CREATE` for `enumerate`, above? It seems that we should have one pattern. I think I would now expect `CREATE OR REPLACE` for functions.","created_at":"2015-02-27T16:01:59Z","updated_at":"2015-02-27T16:01:59Z","html_url":"https://github.com/gratipay/gratipay.com/pull/3206#discussion_r25515929","pull_request_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206","_links":{"self":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments/25515929"},"html":{"href":"https://github.com/gratipay/gratipay.com/pull/3206#discussion_r25515929"},"pull_request":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206"}}},"pull_request":{"url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206","id":30075982,"html_url":"https://github.com/gratipay/gratipay.com/pull/3206","diff_url":"https://github.com/gratipay/gratipay.com/pull/3206.diff","patch_url":"https://github.com/gratipay/gratipay.com/pull/3206.patch","issue_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/3206","number":3206,"state":"open","locked":false,"title":"Separate SQL functions","user":{"login":"Changaco","id":1581590,"avatar_url":"https://avatars.githubusercontent.com/u/1581590?v=3","gravatar_id":"","url":"https://api.github.com/users/Changaco","html_url":"https://github.com/Changaco","followers_url":"https://api.github.com/users/Changaco/followers","following_url":"https://api.github.com/users/Changaco/following{/other_user}","gists_url":"https://api.github.com/users/Changaco/gists{/gist_id}","starred_url":"https://api.github.com/users/Changaco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Changaco/subscriptions","organizations_url":"https://api.github.com/users/Changaco/orgs","repos_url":"https://api.github.com/users/Changaco/repos","events_url":"https://api.github.com/users/Changaco/events{/privacy}","received_events_url":"https://api.github.com/users/Changaco/received_events","type":"User","site_admin":false},"body":"Implements #3162.","created_at":"2015-02-26T13:10:33Z","updated_at":"2015-02-27T16:01:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"891b532146714d586358884c07366b3772df0d14","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206/commits","review_comments_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206/comments","review_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/3206/comments","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/755716d1aeae91666fc499ec479dcd26f59de168","head":{"label":"gratipay:separate-sql-functions","ref":"separate-sql-functions","sha":"755716d1aeae91666fc499ec479dcd26f59de168","user":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"repo":{"id":4521463,"name":"gratipay.com","full_name":"gratipay/gratipay.com","owner":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gratipay/gratipay.com","description":"Gratitude? Gratipay! Weekly payments to people and teams you believe in.","fork":false,"url":"https://api.github.com/repos/gratipay/gratipay.com","forks_url":"https://api.github.com/repos/gratipay/gratipay.com/forks","keys_url":"https://api.github.com/repos/gratipay/gratipay.com/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gratipay/gratipay.com/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gratipay/gratipay.com/teams","hooks_url":"https://api.github.com/repos/gratipay/gratipay.com/hooks","issue_events_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/events{/number}","events_url":"https://api.github.com/repos/gratipay/gratipay.com/events","assignees_url":"https://api.github.com/repos/gratipay/gratipay.com/assignees{/user}","branches_url":"https://api.github.com/repos/gratipay/gratipay.com/branches{/branch}","tags_url":"https://api.github.com/repos/gratipay/gratipay.com/tags","blobs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gratipay/gratipay.com/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/refs{/sha}","trees_url":"https://api.github.com/repos/gratipay/gratipay.com/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/{sha}","languages_url":"https://api.github.com/repos/gratipay/gratipay.com/languages","stargazers_url":"https://api.github.com/repos/gratipay/gratipay.com/stargazers","contributors_url":"https://api.github.com/repos/gratipay/gratipay.com/contributors","subscribers_url":"https://api.github.com/repos/gratipay/gratipay.com/subscribers","subscription_url":"https://api.github.com/repos/gratipay/gratipay.com/subscription","commits_url":"https://api.github.com/repos/gratipay/gratipay.com/commits{/sha}","git_commits_url":"https://api.github.com/repos/gratipay/gratipay.com/git/commits{/sha}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/comments{/number}","issue_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/comments{/number}","contents_url":"https://api.github.com/repos/gratipay/gratipay.com/contents/{+path}","compare_url":"https://api.github.com/repos/gratipay/gratipay.com/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gratipay/gratipay.com/merges","archive_url":"https://api.github.com/repos/gratipay/gratipay.com/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gratipay/gratipay.com/downloads","issues_url":"https://api.github.com/repos/gratipay/gratipay.com/issues{/number}","pulls_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls{/number}","milestones_url":"https://api.github.com/repos/gratipay/gratipay.com/milestones{/number}","notifications_url":"https://api.github.com/repos/gratipay/gratipay.com/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gratipay/gratipay.com/labels{/name}","releases_url":"https://api.github.com/repos/gratipay/gratipay.com/releases{/id}","created_at":"2012-06-01T16:01:02Z","updated_at":"2015-02-27T15:53:28Z","pushed_at":"2015-02-27T15:53:29Z","git_url":"git://github.com/gratipay/gratipay.com.git","ssh_url":"git@github.com:gratipay/gratipay.com.git","clone_url":"https://github.com/gratipay/gratipay.com.git","svn_url":"https://github.com/gratipay/gratipay.com","homepage":"https://gratipay.com/","size":76552,"stargazers_count":811,"watchers_count":811,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":257,"mirror_url":null,"open_issues_count":399,"forks":257,"open_issues":399,"watchers":811,"default_branch":"master"}},"base":{"label":"gratipay:master","ref":"master","sha":"7a4fdd88e2ff74b46f444988665024788845f118","user":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"repo":{"id":4521463,"name":"gratipay.com","full_name":"gratipay/gratipay.com","owner":{"login":"gratipay","id":1744073,"avatar_url":"https://avatars.githubusercontent.com/u/1744073?v=3","gravatar_id":"","url":"https://api.github.com/users/gratipay","html_url":"https://github.com/gratipay","followers_url":"https://api.github.com/users/gratipay/followers","following_url":"https://api.github.com/users/gratipay/following{/other_user}","gists_url":"https://api.github.com/users/gratipay/gists{/gist_id}","starred_url":"https://api.github.com/users/gratipay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gratipay/subscriptions","organizations_url":"https://api.github.com/users/gratipay/orgs","repos_url":"https://api.github.com/users/gratipay/repos","events_url":"https://api.github.com/users/gratipay/events{/privacy}","received_events_url":"https://api.github.com/users/gratipay/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gratipay/gratipay.com","description":"Gratitude? Gratipay! Weekly payments to people and teams you believe in.","fork":false,"url":"https://api.github.com/repos/gratipay/gratipay.com","forks_url":"https://api.github.com/repos/gratipay/gratipay.com/forks","keys_url":"https://api.github.com/repos/gratipay/gratipay.com/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gratipay/gratipay.com/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gratipay/gratipay.com/teams","hooks_url":"https://api.github.com/repos/gratipay/gratipay.com/hooks","issue_events_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/events{/number}","events_url":"https://api.github.com/repos/gratipay/gratipay.com/events","assignees_url":"https://api.github.com/repos/gratipay/gratipay.com/assignees{/user}","branches_url":"https://api.github.com/repos/gratipay/gratipay.com/branches{/branch}","tags_url":"https://api.github.com/repos/gratipay/gratipay.com/tags","blobs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gratipay/gratipay.com/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gratipay/gratipay.com/git/refs{/sha}","trees_url":"https://api.github.com/repos/gratipay/gratipay.com/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gratipay/gratipay.com/statuses/{sha}","languages_url":"https://api.github.com/repos/gratipay/gratipay.com/languages","stargazers_url":"https://api.github.com/repos/gratipay/gratipay.com/stargazers","contributors_url":"https://api.github.com/repos/gratipay/gratipay.com/contributors","subscribers_url":"https://api.github.com/repos/gratipay/gratipay.com/subscribers","subscription_url":"https://api.github.com/repos/gratipay/gratipay.com/subscription","commits_url":"https://api.github.com/repos/gratipay/gratipay.com/commits{/sha}","git_commits_url":"https://api.github.com/repos/gratipay/gratipay.com/git/commits{/sha}","comments_url":"https://api.github.com/repos/gratipay/gratipay.com/comments{/number}","issue_comment_url":"https://api.github.com/repos/gratipay/gratipay.com/issues/comments{/number}","contents_url":"https://api.github.com/repos/gratipay/gratipay.com/contents/{+path}","compare_url":"https://api.github.com/repos/gratipay/gratipay.com/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gratipay/gratipay.com/merges","archive_url":"https://api.github.com/repos/gratipay/gratipay.com/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gratipay/gratipay.com/downloads","issues_url":"https://api.github.com/repos/gratipay/gratipay.com/issues{/number}","pulls_url":"https://api.github.com/repos/gratipay/gratipay.com/pulls{/number}","milestones_url":"https://api.github.com/repos/gratipay/gratipay.com/milestones{/number}","notifications_url":"https://api.github.com/repos/gratipay/gratipay.com/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gratipay/gratipay.com/labels{/name}","releases_url":"https://api.github.com/repos/gratipay/gratipay.com/releases{/id}","created_at":"2012-06-01T16:01:02Z","updated_at":"2015-02-27T15:53:28Z","pushed_at":"2015-02-27T15:53:29Z","git_url":"git://github.com/gratipay/gratipay.com.git","ssh_url":"git@github.com:gratipay/gratipay.com.git","clone_url":"https://github.com/gratipay/gratipay.com.git","svn_url":"https://github.com/gratipay/gratipay.com","homepage":"https://gratipay.com/","size":76552,"stargazers_count":811,"watchers_count":811,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":257,"mirror_url":null,"open_issues_count":399,"forks":257,"open_issues":399,"watchers":811,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206"},"html":{"href":"https://github.com/gratipay/gratipay.com/pull/3206"},"issue":{"href":"https://api.github.com/repos/gratipay/gratipay.com/issues/3206"},"comments":{"href":"https://api.github.com/repos/gratipay/gratipay.com/issues/3206/comments"},"review_comments":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206/comments"},"review_comment":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gratipay/gratipay.com/pulls/3206/commits"},"statuses":{"href":"https://api.github.com/repos/gratipay/gratipay.com/statuses/755716d1aeae91666fc499ec479dcd26f59de168"}}}}