Comparing version 5.6.0 to 5.6.1
@@ -846,4 +846,3 @@ /* globals AbortController */ | ||
key: 'method', | ||
converter: webidl.converters.ByteString, | ||
defaultValue: 'GET' | ||
converter: webidl.converters.ByteString | ||
}, | ||
@@ -850,0 +849,0 @@ { |
@@ -102,3 +102,3 @@ 'use strict' | ||
const { origin, pathname, search } = util.parseURL(new URL(this.location, this.opts.origin)) | ||
const { origin, pathname, search } = util.parseURL(new URL(this.location, this.opts.origin && new URL(this.opts.path, this.opts.origin))) | ||
const path = search ? `${pathname}${search}` : pathname | ||
@@ -105,0 +105,0 @@ |
{ | ||
"name": "undici", | ||
"version": "5.6.0", | ||
"version": "5.6.1", | ||
"description": "An HTTP/1.1 client, written from scratch for Node.js", | ||
@@ -96,3 +96,3 @@ "homepage": "https://undici.nodejs.org", | ||
"tap": "^16.1.0", | ||
"tsd": "^0.21.0", | ||
"tsd": "^0.22.0", | ||
"wait-on": "^6.0.0" | ||
@@ -99,0 +99,0 @@ }, |
@@ -286,2 +286,9 @@ # undici | ||
However, if you want to get only headers, it might be better to use `HEAD` request method. Usage of this method will obviate the need for consumption or cancelling of the response body. See [MDN - HTTP - HTTP request methods - HEAD](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/HEAD) for more details. | ||
```js | ||
const headers = await fetch(url, { method: 'HEAD' }) | ||
.then(res => res.headers) | ||
``` | ||
##### Forbidden and Safelisted Header Names | ||
@@ -288,0 +295,0 @@ |
Sorry, the diff of this file is too big to display
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
859383
403
13072