Skip to content
This repository has been archived by the owner on Jun 18, 2019. It is now read-only.

Commit

Permalink
Fix for #256
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick-rodgers committed Nov 16, 2016
1 parent 971c157 commit 32d1d55
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/net/sprequestexecutorclient.ts
Expand Up @@ -67,7 +67,10 @@ export class SPRequestExecutorClient implements HttpClientImpl {
}
}

return new Response(<any>spResponse.body, {
// issue #256, Cannot have an empty string body when creating a Response with status 204
var body = spResponse.statusCode === 204 ? null : spResponse.body;

return new Response(body, {
headers: responseHeaders,
status: spResponse.statusCode,
statusText: spResponse.statusText,
Expand Down

0 comments on commit 32d1d55

Please sign in to comment.