aboutsummaryrefslogtreecommitdiffstats
path: root/src/service/location.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/service/location.js')
-rw-r--r--src/service/location.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/service/location.js b/src/service/location.js
index d7286291..4d82dfae 100644
--- a/src/service/location.js
+++ b/src/service/location.js
@@ -238,8 +238,9 @@ LocationUrl.prototype = LocationHashbangUrl.prototype = {
return this.$$url;
var match = PATH_MATCH.exec(url);
- this.path(decodeURIComponent(match[1] || '')).search(match[3] || '')
- .hash(match[5] || '', replace);
+ if (match[1]) this.path(decodeURIComponent(match[1]));
+ if (match[2] || match[1]) this.search(match[3] || '');
+ this.hash(match[5] || '', replace);
return this;
},