@podium/utils
Advanced tools
Comparing version 4.4.26 to 4.4.27
@@ -0,1 +1,8 @@ | ||
## [4.4.27](https://github.com/podium-lib/utils/compare/v4.4.26...v4.4.27) (2021-10-26) | ||
### Bug Fixes | ||
* Do not allow origin as a pathname value ([#143](https://github.com/podium-lib/utils/issues/143)) ([ff9785d](https://github.com/podium-lib/utils/commit/ff9785d3e7c4fdfcf9b535a24b59141aed9d55b5)) | ||
## [4.4.26](https://github.com/podium-lib/utils/compare/v4.4.25...v4.4.26) (2021-09-13) | ||
@@ -2,0 +9,0 @@ |
@@ -48,12 +48,10 @@ 'use strict'; | ||
const parts = args | ||
.filter( | ||
arg => | ||
(Array.isArray(arg) && arg.length !== 0) || | ||
(isString(arg) && arg.length !== 0), | ||
) | ||
.flat() | ||
.filter((arg) => { | ||
if (isString(arg) && arg.length !== 0 && !arg.startsWith('http')) { | ||
return true; | ||
} | ||
return false; | ||
}) | ||
.map(arg => { | ||
if (Array.isArray(arg)) { | ||
return arg; | ||
} | ||
if (prefixCheck) { | ||
@@ -65,9 +63,7 @@ prefixCheck = false; | ||
} | ||
return arg.split(separator).filter(item => item); | ||
}); | ||
}) | ||
.flat(); | ||
// NOTE: .apply() is on purpose. It converts all the | ||
// Arrays in the parts Array to one Array | ||
return `${prefix}${[].concat.apply([], parts).join(separator)}`; // eslint-disable-line prefer-spread | ||
return `${prefix}${parts.join(separator)}`; | ||
}; | ||
@@ -74,0 +70,0 @@ |
{ | ||
"name": "@podium/utils", | ||
"version": "4.4.26", | ||
"version": "4.4.27", | ||
"description": "Common generic utility methods shared by @podium modules.", | ||
@@ -59,3 +59,2 @@ "license": "MIT", | ||
"@semantic-release/release-notes-generator": "9.0.3", | ||
"semantic-release": "17.4.7", | ||
"benchmark": "2.1.4", | ||
@@ -68,9 +67,10 @@ "eslint": "7.32.0", | ||
"jest": "26.6.3", | ||
"prettier": "2.2.1" | ||
"prettier": "2.2.1", | ||
"semantic-release": "17.4.7" | ||
}, | ||
"dependencies": { | ||
"@podium/schemas": "4.1.25", | ||
"original-url": "1.2.3", | ||
"camelcase": "6.2.0" | ||
"camelcase": "6.2.0", | ||
"original-url": "1.2.3" | ||
} | ||
} |
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
46602
847