Skip to content

Commit 8565db9

Browse files
committed
fix(router): 修正路由任务中错误的URL引用
将路由任务创建时错误的 `from?.url || null` 引用修正为正确的 `to.url`,确保路由跳转时使用正确的目标URL
1 parent 40d860a commit 8565db9

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

packages/router/src/route-task.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,7 @@ export async function createRouteTask(opts: RouteTaskOptions) {
4141
// 导航重定向
4242
return createRouteTask({
4343
...opts,
44-
to: createRoute(
45-
opts.options,
46-
to.type,
47-
result,
48-
from?.url || null
49-
),
44+
to: createRoute(opts.options, to.type, result, to.url),
5045
from: to
5146
});
5247
}

0 commit comments

Comments
 (0)