Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(vue): Don't call next in Vue router 4 instrumentation #8351

Merged
merged 1 commit into from Jun 19, 2023

Conversation

Lms24
Copy link
Member

@Lms24 Lms24 commented Jun 19, 2023

Vue Router 4 no longer exposes a next resolver function to call inside a beforeEach router guard callback. Instead it will resolve the hook when the callback function returns.

This PR checks if next is available and only calls it then. Also it adjusts the types accordingly and adds a test that previously failed.

fixes #8349

@Lms24 Lms24 merged commit e6ea537 into develop Jun 19, 2023
31 checks passed
@Lms24 Lms24 deleted the lms/fix-vue-router-4-next-call branch June 19, 2023 10:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using vue-router 4.2.2 with Sentry.vueRouterInstrumentation result in TypeError next is not a function
2 participants