{"action":"created","comment":{"url":"https://api.github.com/repos/solnic/transproc/pulls/comments/28612664","id":28612664,"diff_hunk":"@@ -27,7 +29,7 @@ def register(*args, &block)\n   #\n   # @api private\n   def [](name)\n-    functions.fetch(name)\n+    functions[name] or raise Error.new(\"no registered function for #{name}\")","path":"lib/transproc.rb","position":21,"original_position":21,"commit_id":"36228b700f78ecb97940efd59116d3aa739d7738","original_commit_id":"36228b700f78ecb97940efd59116d3aa739d7738","user":{"login":"splattael","id":28908,"avatar_url":"https://avatars.githubusercontent.com/u/28908?v=3","gravatar_id":"","url":"https://api.github.com/users/splattael","html_url":"https://github.com/splattael","followers_url":"https://api.github.com/users/splattael/followers","following_url":"https://api.github.com/users/splattael/following{/other_user}","gists_url":"https://api.github.com/users/splattael/gists{/gist_id}","starred_url":"https://api.github.com/users/splattael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/splattael/subscriptions","organizations_url":"https://api.github.com/users/splattael/orgs","repos_url":"https://api.github.com/users/splattael/repos","events_url":"https://api.github.com/users/splattael/events{/privacy}","received_events_url":"https://api.github.com/users/splattael/received_events","type":"User","site_admin":false},"body":"Also, I'd prefer `function.fetch(name) { raise ... }`.\r\nJust in case.","created_at":"2015-04-17T17:19:24Z","updated_at":"2015-04-17T17:19:24Z","html_url":"https://github.com/solnic/transproc/pull/25#discussion_r28612664","pull_request_url":"https://api.github.com/repos/solnic/transproc/pulls/25","_links":{"self":{"href":"https://api.github.com/repos/solnic/transproc/pulls/comments/28612664"},"html":{"href":"https://github.com/solnic/transproc/pull/25#discussion_r28612664"},"pull_request":{"href":"https://api.github.com/repos/solnic/transproc/pulls/25"}}},"pull_request":{"url":"https://api.github.com/repos/solnic/transproc/pulls/25","id":33541815,"html_url":"https://github.com/solnic/transproc/pull/25","diff_url":"https://github.com/solnic/transproc/pull/25.diff","patch_url":"https://github.com/solnic/transproc/pull/25.patch","issue_url":"https://api.github.com/repos/solnic/transproc/issues/25","number":25,"state":"open","locked":false,"title":"Transproc.register raises error on duplicate registration","user":{"login":"kwando","id":891566,"avatar_url":"https://avatars.githubusercontent.com/u/891566?v=3","gravatar_id":"","url":"https://api.github.com/users/kwando","html_url":"https://github.com/kwando","followers_url":"https://api.github.com/users/kwando/followers","following_url":"https://api.github.com/users/kwando/following{/other_user}","gists_url":"https://api.github.com/users/kwando/gists{/gist_id}","starred_url":"https://api.github.com/users/kwando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwando/subscriptions","organizations_url":"https://api.github.com/users/kwando/orgs","repos_url":"https://api.github.com/users/kwando/repos","events_url":"https://api.github.com/users/kwando/events{/privacy}","received_events_url":"https://api.github.com/users/kwando/received_events","type":"User","site_admin":false},"body":"Transproc.register will raise an error if an function with\nthe given name is already registered.\n\nTransproc[] will raise an error it cannot find the given function.","created_at":"2015-04-17T13:00:53Z","updated_at":"2015-04-17T17:19:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d7176c8d0b4fef6d7db2f225dbdebc8411f44eef","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/solnic/transproc/pulls/25/commits","review_comments_url":"https://api.github.com/repos/solnic/transproc/pulls/25/comments","review_comment_url":"https://api.github.com/repos/solnic/transproc/pulls/comments{/number}","comments_url":"https://api.github.com/repos/solnic/transproc/issues/25/comments","statuses_url":"https://api.github.com/repos/solnic/transproc/statuses/36228b700f78ecb97940efd59116d3aa739d7738","head":{"label":"kwando:raise_errors","ref":"raise_errors","sha":"36228b700f78ecb97940efd59116d3aa739d7738","user":{"login":"kwando","id":891566,"avatar_url":"https://avatars.githubusercontent.com/u/891566?v=3","gravatar_id":"","url":"https://api.github.com/users/kwando","html_url":"https://github.com/kwando","followers_url":"https://api.github.com/users/kwando/followers","following_url":"https://api.github.com/users/kwando/following{/other_user}","gists_url":"https://api.github.com/users/kwando/gists{/gist_id}","starred_url":"https://api.github.com/users/kwando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwando/subscriptions","organizations_url":"https://api.github.com/users/kwando/orgs","repos_url":"https://api.github.com/users/kwando/repos","events_url":"https://api.github.com/users/kwando/events{/privacy}","received_events_url":"https://api.github.com/users/kwando/received_events","type":"User","site_admin":false},"repo":{"id":34077451,"name":"transproc","full_name":"kwando/transproc","owner":{"login":"kwando","id":891566,"avatar_url":"https://avatars.githubusercontent.com/u/891566?v=3","gravatar_id":"","url":"https://api.github.com/users/kwando","html_url":"https://github.com/kwando","followers_url":"https://api.github.com/users/kwando/followers","following_url":"https://api.github.com/users/kwando/following{/other_user}","gists_url":"https://api.github.com/users/kwando/gists{/gist_id}","starred_url":"https://api.github.com/users/kwando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwando/subscriptions","organizations_url":"https://api.github.com/users/kwando/orgs","repos_url":"https://api.github.com/users/kwando/repos","events_url":"https://api.github.com/users/kwando/events{/privacy}","received_events_url":"https://api.github.com/users/kwando/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kwando/transproc","description":"Transform Ruby objects in functional style","fork":true,"url":"https://api.github.com/repos/kwando/transproc","forks_url":"https://api.github.com/repos/kwando/transproc/forks","keys_url":"https://api.github.com/repos/kwando/transproc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kwando/transproc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kwando/transproc/teams","hooks_url":"https://api.github.com/repos/kwando/transproc/hooks","issue_events_url":"https://api.github.com/repos/kwando/transproc/issues/events{/number}","events_url":"https://api.github.com/repos/kwando/transproc/events","assignees_url":"https://api.github.com/repos/kwando/transproc/assignees{/user}","branches_url":"https://api.github.com/repos/kwando/transproc/branches{/branch}","tags_url":"https://api.github.com/repos/kwando/transproc/tags","blobs_url":"https://api.github.com/repos/kwando/transproc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kwando/transproc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kwando/transproc/git/refs{/sha}","trees_url":"https://api.github.com/repos/kwando/transproc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kwando/transproc/statuses/{sha}","languages_url":"https://api.github.com/repos/kwando/transproc/languages","stargazers_url":"https://api.github.com/repos/kwando/transproc/stargazers","contributors_url":"https://api.github.com/repos/kwando/transproc/contributors","subscribers_url":"https://api.github.com/repos/kwando/transproc/subscribers","subscription_url":"https://api.github.com/repos/kwando/transproc/subscription","commits_url":"https://api.github.com/repos/kwando/transproc/commits{/sha}","git_commits_url":"https://api.github.com/repos/kwando/transproc/git/commits{/sha}","comments_url":"https://api.github.com/repos/kwando/transproc/comments{/number}","issue_comment_url":"https://api.github.com/repos/kwando/transproc/issues/comments{/number}","contents_url":"https://api.github.com/repos/kwando/transproc/contents/{+path}","compare_url":"https://api.github.com/repos/kwando/transproc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kwando/transproc/merges","archive_url":"https://api.github.com/repos/kwando/transproc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kwando/transproc/downloads","issues_url":"https://api.github.com/repos/kwando/transproc/issues{/number}","pulls_url":"https://api.github.com/repos/kwando/transproc/pulls{/number}","milestones_url":"https://api.github.com/repos/kwando/transproc/milestones{/number}","notifications_url":"https://api.github.com/repos/kwando/transproc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kwando/transproc/labels{/name}","releases_url":"https://api.github.com/repos/kwando/transproc/releases{/id}","created_at":"2015-04-16T19:58:34Z","updated_at":"2015-04-17T12:54:44Z","pushed_at":"2015-04-17T13:00:46Z","git_url":"git://github.com/kwando/transproc.git","ssh_url":"git@github.com:kwando/transproc.git","clone_url":"https://github.com/kwando/transproc.git","svn_url":"https://github.com/kwando/transproc","homepage":"http://solnic.github.io/transproc/","size":847,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"solnic:master","ref":"master","sha":"058e613a42f774cf937b9f9efc9a72d68514a936","user":{"login":"solnic","id":1066,"avatar_url":"https://avatars.githubusercontent.com/u/1066?v=3","gravatar_id":"","url":"https://api.github.com/users/solnic","html_url":"https://github.com/solnic","followers_url":"https://api.github.com/users/solnic/followers","following_url":"https://api.github.com/users/solnic/following{/other_user}","gists_url":"https://api.github.com/users/solnic/gists{/gist_id}","starred_url":"https://api.github.com/users/solnic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/solnic/subscriptions","organizations_url":"https://api.github.com/users/solnic/orgs","repos_url":"https://api.github.com/users/solnic/repos","events_url":"https://api.github.com/users/solnic/events{/privacy}","received_events_url":"https://api.github.com/users/solnic/received_events","type":"User","site_admin":false},"repo":{"id":28452477,"name":"transproc","full_name":"solnic/transproc","owner":{"login":"solnic","id":1066,"avatar_url":"https://avatars.githubusercontent.com/u/1066?v=3","gravatar_id":"","url":"https://api.github.com/users/solnic","html_url":"https://github.com/solnic","followers_url":"https://api.github.com/users/solnic/followers","following_url":"https://api.github.com/users/solnic/following{/other_user}","gists_url":"https://api.github.com/users/solnic/gists{/gist_id}","starred_url":"https://api.github.com/users/solnic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/solnic/subscriptions","organizations_url":"https://api.github.com/users/solnic/orgs","repos_url":"https://api.github.com/users/solnic/repos","events_url":"https://api.github.com/users/solnic/events{/privacy}","received_events_url":"https://api.github.com/users/solnic/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/solnic/transproc","description":"Transform Ruby objects in functional style","fork":false,"url":"https://api.github.com/repos/solnic/transproc","forks_url":"https://api.github.com/repos/solnic/transproc/forks","keys_url":"https://api.github.com/repos/solnic/transproc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/solnic/transproc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/solnic/transproc/teams","hooks_url":"https://api.github.com/repos/solnic/transproc/hooks","issue_events_url":"https://api.github.com/repos/solnic/transproc/issues/events{/number}","events_url":"https://api.github.com/repos/solnic/transproc/events","assignees_url":"https://api.github.com/repos/solnic/transproc/assignees{/user}","branches_url":"https://api.github.com/repos/solnic/transproc/branches{/branch}","tags_url":"https://api.github.com/repos/solnic/transproc/tags","blobs_url":"https://api.github.com/repos/solnic/transproc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/solnic/transproc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/solnic/transproc/git/refs{/sha}","trees_url":"https://api.github.com/repos/solnic/transproc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/solnic/transproc/statuses/{sha}","languages_url":"https://api.github.com/repos/solnic/transproc/languages","stargazers_url":"https://api.github.com/repos/solnic/transproc/stargazers","contributors_url":"https://api.github.com/repos/solnic/transproc/contributors","subscribers_url":"https://api.github.com/repos/solnic/transproc/subscribers","subscription_url":"https://api.github.com/repos/solnic/transproc/subscription","commits_url":"https://api.github.com/repos/solnic/transproc/commits{/sha}","git_commits_url":"https://api.github.com/repos/solnic/transproc/git/commits{/sha}","comments_url":"https://api.github.com/repos/solnic/transproc/comments{/number}","issue_comment_url":"https://api.github.com/repos/solnic/transproc/issues/comments{/number}","contents_url":"https://api.github.com/repos/solnic/transproc/contents/{+path}","compare_url":"https://api.github.com/repos/solnic/transproc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/solnic/transproc/merges","archive_url":"https://api.github.com/repos/solnic/transproc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/solnic/transproc/downloads","issues_url":"https://api.github.com/repos/solnic/transproc/issues{/number}","pulls_url":"https://api.github.com/repos/solnic/transproc/pulls{/number}","milestones_url":"https://api.github.com/repos/solnic/transproc/milestones{/number}","notifications_url":"https://api.github.com/repos/solnic/transproc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/solnic/transproc/labels{/name}","releases_url":"https://api.github.com/repos/solnic/transproc/releases{/id}","created_at":"2014-12-24T15:15:27Z","updated_at":"2015-04-17T15:19:21Z","pushed_at":"2015-04-17T13:00:54Z","git_url":"git://github.com/solnic/transproc.git","ssh_url":"git@github.com:solnic/transproc.git","clone_url":"https://github.com/solnic/transproc.git","svn_url":"https://github.com/solnic/transproc","homepage":"http://solnic.github.io/transproc/","size":847,"stargazers_count":55,"watchers_count":55,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5,"mirror_url":null,"open_issues_count":1,"forks":5,"open_issues":1,"watchers":55,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/solnic/transproc/pulls/25"},"html":{"href":"https://github.com/solnic/transproc/pull/25"},"issue":{"href":"https://api.github.com/repos/solnic/transproc/issues/25"},"comments":{"href":"https://api.github.com/repos/solnic/transproc/issues/25/comments"},"review_comments":{"href":"https://api.github.com/repos/solnic/transproc/pulls/25/comments"},"review_comment":{"href":"https://api.github.com/repos/solnic/transproc/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/solnic/transproc/pulls/25/commits"},"statuses":{"href":"https://api.github.com/repos/solnic/transproc/statuses/36228b700f78ecb97940efd59116d3aa739d7738"}}}}