mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-27 08:02:01 +00:00
fix(vue-app): duplicated router.base when using context.redirect(object) (#5290)
This commit is contained in:
parent
0eb5ed9763
commit
cf02e8226a
@ -164,7 +164,7 @@ export async function setContext(app, context) {
|
|||||||
status = 302
|
status = 302
|
||||||
}
|
}
|
||||||
if (pathType === 'object') {
|
if (pathType === 'object') {
|
||||||
path = app.router.resolve(path).href
|
path = app.router.resolve(path).route.fullPath
|
||||||
}
|
}
|
||||||
// "/absolute/route", "./relative/route" or "../relative/route"
|
// "/absolute/route", "./relative/route" or "../relative/route"
|
||||||
if (/(^[.]{1,2}\/)|(^\/(?!\/))/.test(path)) {
|
if (/(^[.]{1,2}\/)|(^\/(?!\/))/.test(path)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user