Skip to content

Commit

Permalink
fix: preserve queryString when redirecting to rootRedirect (#169)
Browse files Browse the repository at this point in the history
  • Loading branch information
SnirShechter authored and paulgv committed Jan 14, 2019
1 parent 142dcb0 commit 1ddcac2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/templates/middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ middleware['i18n'] = async ({ app, req, res, route, store, redirect, isHMR }) =>
// Handle root path redirect
const rootRedirect = '<%= options.rootRedirect %>'
if (route.path === '/' && rootRedirect) {
redirect('/' + rootRedirect)
redirect('/' + rootRedirect, route.query)
return
}

Expand Down

0 comments on commit 1ddcac2

Please sign in to comment.