{"action":"created","issue":{"url":"https://api.github.com/repos/bitinn/node-fetch/issues/408","repository_url":"https://api.github.com/repos/bitinn/node-fetch","labels_url":"https://api.github.com/repos/bitinn/node-fetch/issues/408/labels{/name}","comments_url":"https://api.github.com/repos/bitinn/node-fetch/issues/408/comments","events_url":"https://api.github.com/repos/bitinn/node-fetch/issues/408/events","html_url":"https://github.com/bitinn/node-fetch/pull/408","id":301601636,"number":408,"title":"ArrayBuffer body","user":{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-03-01T23:41:56Z","updated_at":"2018-03-04T23:52:30Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/bitinn/node-fetch/pulls/408","html_url":"https://github.com/bitinn/node-fetch/pull/408","diff_url":"https://github.com/bitinn/node-fetch/pull/408.diff","patch_url":"https://github.com/bitinn/node-fetch/pull/408.patch"},"body":"adds support for ArrayBuffer body in requests. Part of #247"},"comment":{"url":"https://api.github.com/repos/bitinn/node-fetch/issues/comments/370276214","html_url":"https://github.com/bitinn/node-fetch/pull/408#issuecomment-370276214","issue_url":"https://api.github.com/repos/bitinn/node-fetch/issues/408","id":370276214,"user":{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false},"created_at":"2018-03-04T23:52:30Z","updated_at":"2018-03-04T23:52:30Z","author_association":"NONE","body":"> consumeBody() (return Body.Promise.resolve(Buffer.from(this.body)), which converts the ArrayBuffer to a Buffer)\r\n\r\nCan you clarify? That change is not working\r\n\r\n```diff\r\ndiff --git a/src/body.js b/src/body.js\r\nindex 8a3bbf4..9e24db9 100644\r\n--- a/src/body.js\r\n+++ b/src/body.js\r\n@@ -79,7 +79,7 @@ Body.prototype = {\r\n \t * @return  Promise\r\n \t */\r\n \tarrayBuffer() {\r\n-\t\treturn consumeBody.call(this).then(buf => buf.buffer.slice(buf.byteOffset, buf.byteOffset + buf.byteLength));\r\n+\t\treturn Body.Promise.resolve(Buffer.from(this.body));\r\n \t},\r\n \r\n \t/**\r\n```\r\n\r\n> extractContentType() (returning null directly is fine)\r\n\r\n👍 cf86d15"}}
{"actor":{"display_login":"gr2m"}}