Skip to content

Commit a22766a

Browse files
committed
fix(router): revert handle server redirect by #5330
Signed-off-by: leesb971204 <leesb971204@gmail.com>
1 parent 918e51e commit a22766a

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

packages/router-core/src/router.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1949,14 +1949,11 @@ export class RouterCore<
19491949
}
19501950
}
19511951

1952-
const latestPublicHref = this.latestLocation.publicHref
1953-
const nextPublicHref = nextLocation.publicHref
1954-
19551952
if (
1956-
trimPath(normalizeUrl(latestPublicHref)) !==
1957-
trimPath(normalizeUrl(nextPublicHref))
1953+
trimPath(normalizeUrl(this.latestLocation.href)) !==
1954+
trimPath(normalizeUrl(nextLocation.href))
19581955
) {
1959-
throw redirect({ href: nextPublicHref })
1956+
throw redirect({ href: nextLocation.href })
19601957
}
19611958
}
19621959

0 commit comments

Comments
 (0)