Skip to content

Commit 838fc58

Browse files
authored
fix(vue): Check for matched route existence before starting transaction (#3973)
1 parent 6b21d76 commit 838fc58

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/vue/src/router.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ export function vueRouterInstrumentation(router: VueRouter): VueRouterInstrument
6161

6262
if (startTransactionOnLocationChange && !isPageLoadNavigation) {
6363
startTransaction({
64-
name: to.name || to.matched[0].path || to.path,
64+
name: to.name || (to.matched[0] && to.matched[0].path) || to.path,
6565
op: 'navigation',
6666
tags,
6767
data,

0 commit comments

Comments
 (0)