route-node
Advanced tools
Comparing version 1.8.3 to 1.8.4
@@ -0,1 +1,11 @@ | ||
<a name="1.8.4"></a> | ||
## [1.8.4](https://github.com/troch/route-node/compare/v1.8.3...v1.8.4) (2017-08-07) | ||
### Bug Fixes | ||
* don't remove trailing slash of `/` if `useTrailingSlash` is set to `false` ([61f4b21](https://github.com/troch/route-node/commit/61f4b21)) | ||
<a name="1.8.3"></a> | ||
@@ -2,0 +12,0 @@ ## [1.8.3](https://github.com/troch/route-node/compare/v1.8.2...v1.8.3) (2017-08-04) |
@@ -925,3 +925,3 @@ define('RouteNode', function () { 'use strict'; | ||
finalPath = /\/$/.test(path) ? path : path + '/'; | ||
} else if (options.trailingSlash === false) { | ||
} else if (options.trailingSlash === false && path !== '/') { | ||
finalPath = /\/$/.test(path) ? path.slice(0, -1) : path; | ||
@@ -928,0 +928,0 @@ } |
@@ -410,3 +410,3 @@ 'use strict'; | ||
finalPath = /\/$/.test(path) ? path : path + '/'; | ||
} else if (options.trailingSlash === false) { | ||
} else if (options.trailingSlash === false && path !== '/') { | ||
finalPath = /\/$/.test(path) ? path.slice(0, -1) : path; | ||
@@ -413,0 +413,0 @@ } |
@@ -929,3 +929,3 @@ (function (global, factory) { | ||
finalPath = /\/$/.test(path) ? path : path + '/'; | ||
} else if (options.trailingSlash === false) { | ||
} else if (options.trailingSlash === false && path !== '/') { | ||
finalPath = /\/$/.test(path) ? path.slice(0, -1) : path; | ||
@@ -932,0 +932,0 @@ } |
@@ -331,3 +331,3 @@ import Path from 'path-parser'; | ||
finalPath = /\/$/.test(path) ? path : `${path}/`; | ||
} else if (options.trailingSlash === false) { | ||
} else if (options.trailingSlash === false && path !== '/') { | ||
finalPath = /\/$/.test(path) ? path.slice(0, -1) : path; | ||
@@ -334,0 +334,0 @@ } |
{ | ||
"name": "route-node", | ||
"version": "1.8.3", | ||
"version": "1.8.4", | ||
"description": "A package to create a tree of named routes", | ||
@@ -5,0 +5,0 @@ "main": "dist/commonjs/route-node.js", |
245653