From 037b7896c00c8a22f5b781408c7b26922eab54ad Mon Sep 17 00:00:00 2001 From: ericpan17 Date: Wed, 17 Apr 2024 11:20:10 -0400 Subject: [PATCH] Update location.js need to fix undefined next error --- src/util/location.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/util/location.js b/src/util/location.js index fb98d4537..22b943891 100644 --- a/src/util/location.js +++ b/src/util/location.js @@ -14,6 +14,9 @@ export function normalizeLocation ( router: ?VueRouter ): Location { let next: Location = typeof raw === 'string' ? { path: raw } : raw + if (!next) { + return {} + } // named target if (next._normalized) { return next