netlify-headers-parser
Advanced tools
Comparing version 4.0.0 to 4.0.1
{ | ||
"name": "netlify-headers-parser", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"description": "Parses Netlify headers into a JavaScript object representation", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -102,3 +102,3 @@ const fs = require('fs') | ||
const { values } = currentHeader | ||
const newValue = values[name] === undefined ? value : `${values[name]},${value}` | ||
const newValue = values[name] === undefined ? value : `${values[name]}, ${value}` | ||
const newHeaders = [...previousHeaders, { ...currentHeader, values: { ...values, [name]: newValue } }] | ||
@@ -105,0 +105,0 @@ return { headers: newHeaders, errors } |
@@ -94,3 +94,3 @@ const isPlainObj = require('is-plain-obj') | ||
if (Array.isArray(rawValue)) { | ||
return rawValue.map((singleValue, index) => normalizeArrayItemValue(`${key}[${index}]`, singleValue)).join(',') | ||
return rawValue.map((singleValue, index) => normalizeArrayItemValue(`${key}[${index}]`, singleValue)).join(', ') | ||
} | ||
@@ -115,5 +115,5 @@ | ||
// [headers.values] | ||
// cache-control = "max-age=0,no-cache,no-store,must-revalidate" | ||
// cache-control = "max-age=0, no-cache, no-store, must-revalidate" | ||
const normalizeMultipleValues = function (value) { | ||
return value.split(MULTIPLE_VALUES_REGEXP).join(',') | ||
return value.split(MULTIPLE_VALUES_REGEXP).join(', ') | ||
} | ||
@@ -120,0 +120,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
17150