query-string-manipulator
Advanced tools
Comparing version 1.1.1 to 1.1.2
@@ -75,3 +75,5 @@ "use strict"; | ||
function mapInputToParams(params) { | ||
return Object.keys(params).reduce(function (aggr, key) { | ||
return Object.keys(params).filter(function (key) { | ||
return params[key] !== undefined; | ||
}).reduce(function (aggr, key) { | ||
if (params[key] instanceof Array) { | ||
@@ -152,5 +154,3 @@ return aggr.concat(params[key].map(function (value) { | ||
function constructUrlParams(params) { | ||
return params.filter(function (param) { | ||
return param.value !== undefined; | ||
}).map(function (param) { | ||
return params.map(function (param) { | ||
return param.value === null ? "".concat(encodeURI(param.key)) : "".concat(encodeURI(param.key), "=").concat(encodeURI(param.value)); | ||
@@ -157,0 +157,0 @@ }).join('&'); |
{ | ||
"name": "query-string-manipulator", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "Manipulate query strings without effort", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
11358