path-parser
Advanced tools
Comparing version 2.0.0 to 2.0.1
@@ -0,1 +1,11 @@ | ||
<a name="2.0.1"></a> | ||
## [2.0.1](https://github.com/troch/path-parser/compare/v2.0.0...v2.0.1) (2016-10-13) | ||
### Bug Fixes | ||
* don't partially match '' against '/' ([eeb378e](https://github.com/troch/path-parser/commit/eeb378e)) | ||
<a name="2.0.0"></a> | ||
@@ -2,0 +12,0 @@ # [2.0.0](https://github.com/troch/path-parser/compare/v1.0.4...v2.0.0) (2016-10-12) |
@@ -322,3 +322,5 @@ define('Path', ['search-params'], function (searchParams) { 'use strict'; | ||
if (!delimiter) return source; | ||
return source.replace(/\\(\/|\?|\.|;)$/, '') + '(\\/|\\?|\\.|;|$)'; | ||
return (/(\/)$/.test(source) ? source : source + '(\\/|\\?|\\.|;|$)' | ||
); | ||
}; | ||
@@ -325,0 +327,0 @@ |
@@ -110,3 +110,5 @@ 'use strict'; | ||
if (!delimiter) return source; | ||
return source.replace(/\\(\/|\?|\.|;)$/, '') + '(\\/|\\?|\\.|;|$)'; | ||
return (/(\/)$/.test(source) ? source : source + '(\\/|\\?|\\.|;|$)' | ||
); | ||
}; | ||
@@ -113,0 +115,0 @@ |
@@ -326,3 +326,5 @@ (function (global, factory) { | ||
if (!delimiter) return source; | ||
return source.replace(/\\(\/|\?|\.|;)$/, '') + '(\\/|\\?|\\.|;|$)'; | ||
return (/(\/)$/.test(source) ? source : source + '(\\/|\\?|\\.|;|$)' | ||
); | ||
}; | ||
@@ -329,0 +331,0 @@ |
@@ -95,3 +95,6 @@ import { getSearch, withoutBrackets, parse, toObject } from 'search-params'; | ||
if (!delimiter) return source; | ||
return source.replace(/\\(\/|\?|\.|;)$/, '') + '(\\/|\\?|\\.|;|$)'; | ||
return /(\/)$/.test(source) | ||
? source | ||
: source + '(\\/|\\?|\\.|;|$)'; | ||
}; | ||
@@ -98,0 +101,0 @@ |
{ | ||
"name": "path-parser", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "A small utility to parse, match and generate paths", | ||
@@ -5,0 +5,0 @@ "main": "dist/commonjs/path-parser.js", |
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
234463
1896