diff options
| author | Egor Tensin <egor@tensin.name> | 2025-12-16 16:51:48 +0100 |
|---|---|---|
| committer | Egor Tensin <egor@tensin.name> | 2025-12-16 16:51:54 +0100 |
| commit | 342fb8ba128c1fbbf5195a7b5d56cb5b8f8fdca9 (patch) | |
| tree | 1af9b90985a2685c70e8e756eabc62a21ca362bb /node_modules/undici/lib/cookies/index.js | |
| parent | bump dependencies (diff) | |
| download | cleanup-path-342fb8ba128c1fbbf5195a7b5d56cb5b8f8fdca9.tar.gz cleanup-path-342fb8ba128c1fbbf5195a7b5d56cb5b8f8fdca9.zip | |
bump dependencies
Diffstat (limited to 'node_modules/undici/lib/cookies/index.js')
| -rw-r--r-- | node_modules/undici/lib/cookies/index.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/node_modules/undici/lib/cookies/index.js b/node_modules/undici/lib/cookies/index.js index c9c1f28..f867b19 100644 --- a/node_modules/undici/lib/cookies/index.js +++ b/node_modules/undici/lib/cookies/index.js @@ -1,7 +1,7 @@ 'use strict' const { parseSetCookie } = require('./parse') -const { stringify, getHeadersList } = require('./util') +const { stringify } = require('./util') const { webidl } = require('../fetch/webidl') const { Headers } = require('../fetch/headers') @@ -77,14 +77,13 @@ function getSetCookies (headers) { webidl.brandCheck(headers, Headers, { strict: false }) - const cookies = getHeadersList(headers).cookies + const cookies = headers.getSetCookie() if (!cookies) { return [] } - // In older versions of undici, cookies is a list of name:value. - return cookies.map((pair) => parseSetCookie(Array.isArray(pair) ? pair[1] : pair)) + return cookies.map((pair) => parseSetCookie(pair)) } /** |
