{"action":"created","comment":{"url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/comments/81973795","pull_request_review_id":2913588,"id":81973795,"diff_hunk":"@@ -0,0 +1,13 @@\n+'use strict'\n+\n+module.exports = function getWebCrypto () {\n+  if (typeof window !== 'undefined') {","path":"src/crypto/webcrypto-browser.js","position":4,"original_position":4,"commit_id":"cea6374f3c821d11d16ca5b0aea9a1c8a3c31dbd","original_commit_id":"cea6374f3c821d11d16ca5b0aea9a1c8a3c31dbd","user":{"login":"dignifiedquire","id":790842,"avatar_url":"https://avatars.githubusercontent.com/u/790842?v=3","gravatar_id":"","url":"https://api.github.com/users/dignifiedquire","html_url":"https://github.com/dignifiedquire","followers_url":"https://api.github.com/users/dignifiedquire/followers","following_url":"https://api.github.com/users/dignifiedquire/following{/other_user}","gists_url":"https://api.github.com/users/dignifiedquire/gists{/gist_id}","starred_url":"https://api.github.com/users/dignifiedquire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dignifiedquire/subscriptions","organizations_url":"https://api.github.com/users/dignifiedquire/orgs","repos_url":"https://api.github.com/users/dignifiedquire/repos","events_url":"https://api.github.com/users/dignifiedquire/events{/privacy}","received_events_url":"https://api.github.com/users/dignifiedquire/received_events","type":"User","site_admin":false},"body":"No, we don't want to know if we are in node, we explicitly want to know if there is a `window` object available.","created_at":"2016-10-05T13:40:09Z","updated_at":"2016-10-05T13:40:10Z","html_url":"https://github.com/libp2p/js-libp2p-crypto/pull/12#discussion_r81973795","pull_request_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/comments/81973795"},"html":{"href":"https://github.com/libp2p/js-libp2p-crypto/pull/12#discussion_r81973795"},"pull_request":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12","id":86508434,"html_url":"https://github.com/libp2p/js-libp2p-crypto/pull/12","diff_url":"https://github.com/libp2p/js-libp2p-crypto/pull/12.diff","patch_url":"https://github.com/libp2p/js-libp2p-crypto/pull/12.patch","issue_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/12","number":12,"state":"open","locked":false,"title":"Replace elliptic.js and node-forge with webcrypto ","user":{"login":"dignifiedquire","id":790842,"avatar_url":"https://avatars.githubusercontent.com/u/790842?v=3","gravatar_id":"","url":"https://api.github.com/users/dignifiedquire","html_url":"https://github.com/dignifiedquire","followers_url":"https://api.github.com/users/dignifiedquire/followers","following_url":"https://api.github.com/users/dignifiedquire/following{/other_user}","gists_url":"https://api.github.com/users/dignifiedquire/gists{/gist_id}","starred_url":"https://api.github.com/users/dignifiedquire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dignifiedquire/subscriptions","organizations_url":"https://api.github.com/users/dignifiedquire/orgs","repos_url":"https://api.github.com/users/dignifiedquire/repos","events_url":"https://api.github.com/users/dignifiedquire/events{/privacy}","received_events_url":"https://api.github.com/users/dignifiedquire/received_events","type":"User","site_admin":false},"body":"- No more `node-forge`\r\n- No more `elliptic.js`\r\n\r\nNeeds https://github.com/multiformats/js-multihashing/pull/12\r\n\r\nStats can be found here: https://github.com/libp2p/js-libp2p-crypto/blob/webcrypto/stats.md","created_at":"2016-09-23T12:59:30Z","updated_at":"2016-10-05T13:40:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ad2bb3e776b4e3111d995b8d07add31000fddd8c","assignee":{"login":"diasdavid","id":1211152,"avatar_url":"https://avatars.githubusercontent.com/u/1211152?v=3","gravatar_id":"","url":"https://api.github.com/users/diasdavid","html_url":"https://github.com/diasdavid","followers_url":"https://api.github.com/users/diasdavid/followers","following_url":"https://api.github.com/users/diasdavid/following{/other_user}","gists_url":"https://api.github.com/users/diasdavid/gists{/gist_id}","starred_url":"https://api.github.com/users/diasdavid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/diasdavid/subscriptions","organizations_url":"https://api.github.com/users/diasdavid/orgs","repos_url":"https://api.github.com/users/diasdavid/repos","events_url":"https://api.github.com/users/diasdavid/events{/privacy}","received_events_url":"https://api.github.com/users/diasdavid/received_events","type":"User","site_admin":false},"assignees":[{"login":"diasdavid","id":1211152,"avatar_url":"https://avatars.githubusercontent.com/u/1211152?v=3","gravatar_id":"","url":"https://api.github.com/users/diasdavid","html_url":"https://github.com/diasdavid","followers_url":"https://api.github.com/users/diasdavid/followers","following_url":"https://api.github.com/users/diasdavid/following{/other_user}","gists_url":"https://api.github.com/users/diasdavid/gists{/gist_id}","starred_url":"https://api.github.com/users/diasdavid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/diasdavid/subscriptions","organizations_url":"https://api.github.com/users/diasdavid/orgs","repos_url":"https://api.github.com/users/diasdavid/repos","events_url":"https://api.github.com/users/diasdavid/events{/privacy}","received_events_url":"https://api.github.com/users/diasdavid/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12/commits","review_comments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12/comments","review_comment_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/comments{/number}","comments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/12/comments","statuses_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/statuses/cea6374f3c821d11d16ca5b0aea9a1c8a3c31dbd","head":{"label":"libp2p:webcrypto","ref":"webcrypto","sha":"cea6374f3c821d11d16ca5b0aea9a1c8a3c31dbd","user":{"login":"libp2p","id":14838238,"avatar_url":"https://avatars.githubusercontent.com/u/14838238?v=3","gravatar_id":"","url":"https://api.github.com/users/libp2p","html_url":"https://github.com/libp2p","followers_url":"https://api.github.com/users/libp2p/followers","following_url":"https://api.github.com/users/libp2p/following{/other_user}","gists_url":"https://api.github.com/users/libp2p/gists{/gist_id}","starred_url":"https://api.github.com/users/libp2p/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/libp2p/subscriptions","organizations_url":"https://api.github.com/users/libp2p/orgs","repos_url":"https://api.github.com/users/libp2p/repos","events_url":"https://api.github.com/users/libp2p/events{/privacy}","received_events_url":"https://api.github.com/users/libp2p/received_events","type":"Organization","site_admin":false},"repo":{"id":59225160,"name":"js-libp2p-crypto","full_name":"libp2p/js-libp2p-crypto","owner":{"login":"libp2p","id":14838238,"avatar_url":"https://avatars.githubusercontent.com/u/14838238?v=3","gravatar_id":"","url":"https://api.github.com/users/libp2p","html_url":"https://github.com/libp2p","followers_url":"https://api.github.com/users/libp2p/followers","following_url":"https://api.github.com/users/libp2p/following{/other_user}","gists_url":"https://api.github.com/users/libp2p/gists{/gist_id}","starred_url":"https://api.github.com/users/libp2p/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/libp2p/subscriptions","organizations_url":"https://api.github.com/users/libp2p/orgs","repos_url":"https://api.github.com/users/libp2p/repos","events_url":"https://api.github.com/users/libp2p/events{/privacy}","received_events_url":"https://api.github.com/users/libp2p/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/libp2p/js-libp2p-crypto","description":"Crypto primitives for libp2p in JavaScript","fork":false,"url":"https://api.github.com/repos/libp2p/js-libp2p-crypto","forks_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/forks","keys_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/teams","hooks_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/hooks","issue_events_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/events{/number}","events_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/events","assignees_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/assignees{/user}","branches_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/branches{/branch}","tags_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/tags","blobs_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/refs{/sha}","trees_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/statuses/{sha}","languages_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/languages","stargazers_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/stargazers","contributors_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/contributors","subscribers_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/subscribers","subscription_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/subscription","commits_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/commits{/sha}","git_commits_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/commits{/sha}","comments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/comments{/number}","issue_comment_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/comments{/number}","contents_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/contents/{+path}","compare_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/merges","archive_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/downloads","issues_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues{/number}","pulls_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls{/number}","milestones_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/milestones{/number}","notifications_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/labels{/name}","releases_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/releases{/id}","deployments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/deployments","created_at":"2016-05-19T16:48:33Z","updated_at":"2016-09-06T14:50:10Z","pushed_at":"2016-10-04T16:54:15Z","git_url":"git://github.com/libp2p/js-libp2p-crypto.git","ssh_url":"git@github.com:libp2p/js-libp2p-crypto.git","clone_url":"https://github.com/libp2p/js-libp2p-crypto.git","svn_url":"https://github.com/libp2p/js-libp2p-crypto","homepage":null,"size":282,"stargazers_count":4,"watchers_count":4,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":4,"default_branch":"master"}},"base":{"label":"libp2p:master","ref":"master","sha":"73a5258876fe53ffcb831907d24ac3111bc3efc2","user":{"login":"libp2p","id":14838238,"avatar_url":"https://avatars.githubusercontent.com/u/14838238?v=3","gravatar_id":"","url":"https://api.github.com/users/libp2p","html_url":"https://github.com/libp2p","followers_url":"https://api.github.com/users/libp2p/followers","following_url":"https://api.github.com/users/libp2p/following{/other_user}","gists_url":"https://api.github.com/users/libp2p/gists{/gist_id}","starred_url":"https://api.github.com/users/libp2p/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/libp2p/subscriptions","organizations_url":"https://api.github.com/users/libp2p/orgs","repos_url":"https://api.github.com/users/libp2p/repos","events_url":"https://api.github.com/users/libp2p/events{/privacy}","received_events_url":"https://api.github.com/users/libp2p/received_events","type":"Organization","site_admin":false},"repo":{"id":59225160,"name":"js-libp2p-crypto","full_name":"libp2p/js-libp2p-crypto","owner":{"login":"libp2p","id":14838238,"avatar_url":"https://avatars.githubusercontent.com/u/14838238?v=3","gravatar_id":"","url":"https://api.github.com/users/libp2p","html_url":"https://github.com/libp2p","followers_url":"https://api.github.com/users/libp2p/followers","following_url":"https://api.github.com/users/libp2p/following{/other_user}","gists_url":"https://api.github.com/users/libp2p/gists{/gist_id}","starred_url":"https://api.github.com/users/libp2p/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/libp2p/subscriptions","organizations_url":"https://api.github.com/users/libp2p/orgs","repos_url":"https://api.github.com/users/libp2p/repos","events_url":"https://api.github.com/users/libp2p/events{/privacy}","received_events_url":"https://api.github.com/users/libp2p/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/libp2p/js-libp2p-crypto","description":"Crypto primitives for libp2p in JavaScript","fork":false,"url":"https://api.github.com/repos/libp2p/js-libp2p-crypto","forks_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/forks","keys_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/teams","hooks_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/hooks","issue_events_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/events{/number}","events_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/events","assignees_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/assignees{/user}","branches_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/branches{/branch}","tags_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/tags","blobs_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/refs{/sha}","trees_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/statuses/{sha}","languages_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/languages","stargazers_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/stargazers","contributors_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/contributors","subscribers_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/subscribers","subscription_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/subscription","commits_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/commits{/sha}","git_commits_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/git/commits{/sha}","comments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/comments{/number}","issue_comment_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/comments{/number}","contents_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/contents/{+path}","compare_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/merges","archive_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/downloads","issues_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues{/number}","pulls_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls{/number}","milestones_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/milestones{/number}","notifications_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/labels{/name}","releases_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/releases{/id}","deployments_url":"https://api.github.com/repos/libp2p/js-libp2p-crypto/deployments","created_at":"2016-05-19T16:48:33Z","updated_at":"2016-09-06T14:50:10Z","pushed_at":"2016-10-04T16:54:15Z","git_url":"git://github.com/libp2p/js-libp2p-crypto.git","ssh_url":"git@github.com:libp2p/js-libp2p-crypto.git","clone_url":"https://github.com/libp2p/js-libp2p-crypto.git","svn_url":"https://github.com/libp2p/js-libp2p-crypto","homepage":null,"size":282,"stargazers_count":4,"watchers_count":4,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12"},"html":{"href":"https://github.com/libp2p/js-libp2p-crypto/pull/12"},"issue":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/12"},"comments":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/libp2p/js-libp2p-crypto/statuses/cea6374f3c821d11d16ca5b0aea9a1c8a3c31dbd"}}}}
{"actor":{"display_login":"dignifiedquire"}}