FIX: Routing to default homepage with query params was broken

This commit is contained in:
Robin Ward 2016-12-22 11:37:17 -05:00
parent 5aee2673c7
commit b9fc9dc9fc
1 changed files with 6 additions and 1 deletions

View File

@ -8,7 +8,12 @@ const BareRouter = Ember.Router.extend({
handleURL(url) {
const params = url.split('?');
if (params[0] === "/") { url = defaultHomepage(); }
if (params[0] === "/") {
url = defaultHomepage();
if (params[1] && params[1].length) {
url = `${url}?${params[1]}`;
}
}
return this._super(url);
}
});