Comparing version 2.62.0 to 2.63.0
## Change Log | ||
### v2.63.0 (2015/09/21) | ||
- [#1772](https://github.com/request/request/pull/1772) Set default application/json content-type when using json option (@jzaefferer) | ||
### v2.62.0 (2015/09/15) | ||
@@ -4,0 +7,0 @@ - [#1768](https://github.com/request/request/pull/1768) Add node 4.0 to the list of build targets (@simov) |
@@ -10,3 +10,3 @@ { | ||
], | ||
"version": "2.62.0", | ||
"version": "2.63.0", | ||
"author": "Mikeal Rogers <mikeal.rogers@gmail.com>", | ||
@@ -13,0 +13,0 @@ "repository": { |
@@ -1201,2 +1201,5 @@ 'use strict' | ||
self._json = true | ||
if (!self.hasHeader('content-type')) { | ||
self.setHeader('content-type', 'application/json') | ||
} | ||
if (typeof val === 'boolean') { | ||
@@ -1209,11 +1212,5 @@ if (self.body !== undefined) { | ||
} | ||
if (!self.hasHeader('content-type')) { | ||
self.setHeader('content-type', 'application/json') | ||
} | ||
} | ||
} else { | ||
self.body = safeStringify(val) | ||
if (!self.hasHeader('content-type')) { | ||
self.setHeader('content-type', 'application/json') | ||
} | ||
} | ||
@@ -1220,0 +1217,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
186282
2353