aboutsummaryrefslogtreecommitdiffstats
path: root/src/ngRoute/route.js
diff options
context:
space:
mode:
authorNicola Peduzzi2013-08-06 17:35:48 +0200
committerVojta Jina2013-10-04 08:45:47 -0700
commit0ff86c323359fba1a60bacab178e3c68528f8e1f (patch)
treefc5add8ccb65bf5f93d57eba9303aec7cdfb1535 /src/ngRoute/route.js
parent31f190d4d53921d32253ba80d9ebe57d6c1de82b (diff)
downloadangular.js-0ff86c323359fba1a60bacab178e3c68528f8e1f.tar.bz2
fix(routeProvider): parametrized routes do not match against locations that would not valorize each parameters.
Diffstat (limited to 'src/ngRoute/route.js')
-rw-r--r--src/ngRoute/route.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ngRoute/route.js b/src/ngRoute/route.js
index cd911ada..8a6dacd4 100644
--- a/src/ngRoute/route.js
+++ b/src/ngRoute/route.js
@@ -177,7 +177,9 @@ function $RouteProvider(){
+ (optional ? '' : slash)
+ '(?:'
+ (optional ? slash : '')
- + (star && '(.+)?' || '([^/]+)?') + ')'
+ + (star && '(.+?)' || '([^/]+)')
+ + (optional || '')
+ + ')'
+ (optional || '');
})
.replace(/([\/$\*])/g, '\\$1');