Skip to content

Commit

Permalink
fix zuiidea#924 404 Not Found after router change
Browse files Browse the repository at this point in the history
  • Loading branch information
superlbr committed Dec 11, 2018
1 parent 94c8e21 commit 0949a29
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,9 +246,8 @@ export function getLocale() {
export function setLocale(language) {
if (getLocale() !== language) {
umiRouter.push({
pathname: `/${language}${deLangPrefix(window.location.pathname)}${
window.location.search
}`,
pathname: `/${language}${deLangPrefix(window.location.pathname)}`,
search: window.location.search,
})
}
}

0 comments on commit 0949a29

Please sign in to comment.