{"action":"closed","number":425,"pull_request":{"url":"https://api.github.com/repos/pgte/nock/pulls/425","id":53705691,"html_url":"https://github.com/pgte/nock/pull/425","diff_url":"https://github.com/pgte/nock/pull/425.diff","patch_url":"https://github.com/pgte/nock/pull/425.patch","issue_url":"https://api.github.com/repos/pgte/nock/issues/425","number":425,"state":"closed","locked":false,"title":"Fix matchBody for multipart requests","user":{"login":"aronwoost","id":408962,"avatar_url":"https://avatars.githubusercontent.com/u/408962?v=3","gravatar_id":"","url":"https://api.github.com/users/aronwoost","html_url":"https://github.com/aronwoost","followers_url":"https://api.github.com/users/aronwoost/followers","following_url":"https://api.github.com/users/aronwoost/following{/other_user}","gists_url":"https://api.github.com/users/aronwoost/gists{/gist_id}","starred_url":"https://api.github.com/users/aronwoost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aronwoost/subscriptions","organizations_url":"https://api.github.com/users/aronwoost/orgs","repos_url":"https://api.github.com/users/aronwoost/repos","events_url":"https://api.github.com/users/aronwoost/events{/privacy}","received_events_url":"https://api.github.com/users/aronwoost/received_events","type":"User","site_admin":false},"body":"Ok, this one took me a while.\r\n\r\n`matchBody` [strips line endings](https://github.com/pgte/nock/blob/master/lib/match_body.js#L18) to be consistent across OSs. While this is cool in 99.99% of the cases, it fails when it comes to multipart requests, since mulitpart parsers depend on the line breaks.\r\n\r\nThis PR disables stripping when `Content-Type` header contains \"multipart\".\r\n\r\nAdditionaly a bug is fixed, where matchBody was throwing, when headers came as array (node-fetch style #399, #400).","created_at":"2015-12-15T13:55:37Z","updated_at":"2015-12-16T11:04:57Z","closed_at":"2015-12-16T11:04:57Z","merged_at":"2015-12-16T11:04:57Z","merge_commit_sha":"5975523195bb8465eb254a3c54a4ac6d2551aad3","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/pgte/nock/pulls/425/commits","review_comments_url":"https://api.github.com/repos/pgte/nock/pulls/425/comments","review_comment_url":"https://api.github.com/repos/pgte/nock/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pgte/nock/issues/425/comments","statuses_url":"https://api.github.com/repos/pgte/nock/statuses/014283b261a0eea14e02aaed982d0068a5da7d23","head":{"label":"aronwoost:multipart-fix","ref":"multipart-fix","sha":"014283b261a0eea14e02aaed982d0068a5da7d23","user":{"login":"aronwoost","id":408962,"avatar_url":"https://avatars.githubusercontent.com/u/408962?v=3","gravatar_id":"","url":"https://api.github.com/users/aronwoost","html_url":"https://github.com/aronwoost","followers_url":"https://api.github.com/users/aronwoost/followers","following_url":"https://api.github.com/users/aronwoost/following{/other_user}","gists_url":"https://api.github.com/users/aronwoost/gists{/gist_id}","starred_url":"https://api.github.com/users/aronwoost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aronwoost/subscriptions","organizations_url":"https://api.github.com/users/aronwoost/orgs","repos_url":"https://api.github.com/users/aronwoost/repos","events_url":"https://api.github.com/users/aronwoost/events{/privacy}","received_events_url":"https://api.github.com/users/aronwoost/received_events","type":"User","site_admin":false},"repo":{"id":44096895,"name":"nock","full_name":"aronwoost/nock","owner":{"login":"aronwoost","id":408962,"avatar_url":"https://avatars.githubusercontent.com/u/408962?v=3","gravatar_id":"","url":"https://api.github.com/users/aronwoost","html_url":"https://github.com/aronwoost","followers_url":"https://api.github.com/users/aronwoost/followers","following_url":"https://api.github.com/users/aronwoost/following{/other_user}","gists_url":"https://api.github.com/users/aronwoost/gists{/gist_id}","starred_url":"https://api.github.com/users/aronwoost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aronwoost/subscriptions","organizations_url":"https://api.github.com/users/aronwoost/orgs","repos_url":"https://api.github.com/users/aronwoost/repos","events_url":"https://api.github.com/users/aronwoost/events{/privacy}","received_events_url":"https://api.github.com/users/aronwoost/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/aronwoost/nock","description":"HTTP mocking and expectations library","fork":true,"url":"https://api.github.com/repos/aronwoost/nock","forks_url":"https://api.github.com/repos/aronwoost/nock/forks","keys_url":"https://api.github.com/repos/aronwoost/nock/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aronwoost/nock/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aronwoost/nock/teams","hooks_url":"https://api.github.com/repos/aronwoost/nock/hooks","issue_events_url":"https://api.github.com/repos/aronwoost/nock/issues/events{/number}","events_url":"https://api.github.com/repos/aronwoost/nock/events","assignees_url":"https://api.github.com/repos/aronwoost/nock/assignees{/user}","branches_url":"https://api.github.com/repos/aronwoost/nock/branches{/branch}","tags_url":"https://api.github.com/repos/aronwoost/nock/tags","blobs_url":"https://api.github.com/repos/aronwoost/nock/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aronwoost/nock/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aronwoost/nock/git/refs{/sha}","trees_url":"https://api.github.com/repos/aronwoost/nock/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aronwoost/nock/statuses/{sha}","languages_url":"https://api.github.com/repos/aronwoost/nock/languages","stargazers_url":"https://api.github.com/repos/aronwoost/nock/stargazers","contributors_url":"https://api.github.com/repos/aronwoost/nock/contributors","subscribers_url":"https://api.github.com/repos/aronwoost/nock/subscribers","subscription_url":"https://api.github.com/repos/aronwoost/nock/subscription","commits_url":"https://api.github.com/repos/aronwoost/nock/commits{/sha}","git_commits_url":"https://api.github.com/repos/aronwoost/nock/git/commits{/sha}","comments_url":"https://api.github.com/repos/aronwoost/nock/comments{/number}","issue_comment_url":"https://api.github.com/repos/aronwoost/nock/issues/comments{/number}","contents_url":"https://api.github.com/repos/aronwoost/nock/contents/{+path}","compare_url":"https://api.github.com/repos/aronwoost/nock/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aronwoost/nock/merges","archive_url":"https://api.github.com/repos/aronwoost/nock/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aronwoost/nock/downloads","issues_url":"https://api.github.com/repos/aronwoost/nock/issues{/number}","pulls_url":"https://api.github.com/repos/aronwoost/nock/pulls{/number}","milestones_url":"https://api.github.com/repos/aronwoost/nock/milestones{/number}","notifications_url":"https://api.github.com/repos/aronwoost/nock/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aronwoost/nock/labels{/name}","releases_url":"https://api.github.com/repos/aronwoost/nock/releases{/id}","created_at":"2015-10-12T09:17:48Z","updated_at":"2015-10-12T09:17:49Z","pushed_at":"2015-12-15T15:07:47Z","git_url":"git://github.com/aronwoost/nock.git","ssh_url":"git@github.com:aronwoost/nock.git","clone_url":"https://github.com/aronwoost/nock.git","svn_url":"https://github.com/aronwoost/nock","homepage":"","size":1278,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pgte:master","ref":"master","sha":"47b082fd0583465ece9f69765d2d24d7731bb834","user":{"login":"pgte","id":47910,"avatar_url":"https://avatars.githubusercontent.com/u/47910?v=3","gravatar_id":"","url":"https://api.github.com/users/pgte","html_url":"https://github.com/pgte","followers_url":"https://api.github.com/users/pgte/followers","following_url":"https://api.github.com/users/pgte/following{/other_user}","gists_url":"https://api.github.com/users/pgte/gists{/gist_id}","starred_url":"https://api.github.com/users/pgte/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pgte/subscriptions","organizations_url":"https://api.github.com/users/pgte/orgs","repos_url":"https://api.github.com/users/pgte/repos","events_url":"https://api.github.com/users/pgte/events{/privacy}","received_events_url":"https://api.github.com/users/pgte/received_events","type":"User","site_admin":false},"repo":{"id":2436267,"name":"nock","full_name":"pgte/nock","owner":{"login":"pgte","id":47910,"avatar_url":"https://avatars.githubusercontent.com/u/47910?v=3","gravatar_id":"","url":"https://api.github.com/users/pgte","html_url":"https://github.com/pgte","followers_url":"https://api.github.com/users/pgte/followers","following_url":"https://api.github.com/users/pgte/following{/other_user}","gists_url":"https://api.github.com/users/pgte/gists{/gist_id}","starred_url":"https://api.github.com/users/pgte/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pgte/subscriptions","organizations_url":"https://api.github.com/users/pgte/orgs","repos_url":"https://api.github.com/users/pgte/repos","events_url":"https://api.github.com/users/pgte/events{/privacy}","received_events_url":"https://api.github.com/users/pgte/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pgte/nock","description":"HTTP mocking and expectations library","fork":false,"url":"https://api.github.com/repos/pgte/nock","forks_url":"https://api.github.com/repos/pgte/nock/forks","keys_url":"https://api.github.com/repos/pgte/nock/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pgte/nock/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pgte/nock/teams","hooks_url":"https://api.github.com/repos/pgte/nock/hooks","issue_events_url":"https://api.github.com/repos/pgte/nock/issues/events{/number}","events_url":"https://api.github.com/repos/pgte/nock/events","assignees_url":"https://api.github.com/repos/pgte/nock/assignees{/user}","branches_url":"https://api.github.com/repos/pgte/nock/branches{/branch}","tags_url":"https://api.github.com/repos/pgte/nock/tags","blobs_url":"https://api.github.com/repos/pgte/nock/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pgte/nock/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pgte/nock/git/refs{/sha}","trees_url":"https://api.github.com/repos/pgte/nock/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pgte/nock/statuses/{sha}","languages_url":"https://api.github.com/repos/pgte/nock/languages","stargazers_url":"https://api.github.com/repos/pgte/nock/stargazers","contributors_url":"https://api.github.com/repos/pgte/nock/contributors","subscribers_url":"https://api.github.com/repos/pgte/nock/subscribers","subscription_url":"https://api.github.com/repos/pgte/nock/subscription","commits_url":"https://api.github.com/repos/pgte/nock/commits{/sha}","git_commits_url":"https://api.github.com/repos/pgte/nock/git/commits{/sha}","comments_url":"https://api.github.com/repos/pgte/nock/comments{/number}","issue_comment_url":"https://api.github.com/repos/pgte/nock/issues/comments{/number}","contents_url":"https://api.github.com/repos/pgte/nock/contents/{+path}","compare_url":"https://api.github.com/repos/pgte/nock/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pgte/nock/merges","archive_url":"https://api.github.com/repos/pgte/nock/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pgte/nock/downloads","issues_url":"https://api.github.com/repos/pgte/nock/issues{/number}","pulls_url":"https://api.github.com/repos/pgte/nock/pulls{/number}","milestones_url":"https://api.github.com/repos/pgte/nock/milestones{/number}","notifications_url":"https://api.github.com/repos/pgte/nock/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pgte/nock/labels{/name}","releases_url":"https://api.github.com/repos/pgte/nock/releases{/id}","created_at":"2011-09-22T10:08:03Z","updated_at":"2015-12-16T09:19:33Z","pushed_at":"2015-12-16T11:04:56Z","git_url":"git://github.com/pgte/nock.git","ssh_url":"git@github.com:pgte/nock.git","clone_url":"https://github.com/pgte/nock.git","svn_url":"https://github.com/pgte/nock","homepage":"","size":1647,"stargazers_count":2775,"watchers_count":2775,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":232,"mirror_url":null,"open_issues_count":20,"forks":232,"open_issues":20,"watchers":2775,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pgte/nock/pulls/425"},"html":{"href":"https://github.com/pgte/nock/pull/425"},"issue":{"href":"https://api.github.com/repos/pgte/nock/issues/425"},"comments":{"href":"https://api.github.com/repos/pgte/nock/issues/425/comments"},"review_comments":{"href":"https://api.github.com/repos/pgte/nock/pulls/425/comments"},"review_comment":{"href":"https://api.github.com/repos/pgte/nock/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pgte/nock/pulls/425/commits"},"statuses":{"href":"https://api.github.com/repos/pgte/nock/statuses/014283b261a0eea14e02aaed982d0068a5da7d23"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"pgte","id":47910,"avatar_url":"https://avatars.githubusercontent.com/u/47910?v=3","gravatar_id":"","url":"https://api.github.com/users/pgte","html_url":"https://github.com/pgte","followers_url":"https://api.github.com/users/pgte/followers","following_url":"https://api.github.com/users/pgte/following{/other_user}","gists_url":"https://api.github.com/users/pgte/gists{/gist_id}","starred_url":"https://api.github.com/users/pgte/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pgte/subscriptions","organizations_url":"https://api.github.com/users/pgte/orgs","repos_url":"https://api.github.com/users/pgte/repos","events_url":"https://api.github.com/users/pgte/events{/privacy}","received_events_url":"https://api.github.com/users/pgte/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"commits":2,"additions":53,"deletions":10,"changed_files":2}}