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(sveltekit): update wrapServerRouteWithSentry to respect ParamMatchers #13390

Merged
merged 1 commit into from
Oct 9, 2024
Merged

fix(sveltekit): update wrapServerRouteWithSentry to respect ParamMatchers #13390

merged 1 commit into from
Oct 9, 2024

Conversation

gurpreetatwal
Copy link
Contributor

SvelteKit narrows the type of event.params based on ParamMatchers that are defined in the path, by making the function generic we can respect the narrowed type

Before submitting a pull request, please take a look at our
Contributing guidelines and verify:

  • If you've added code that should be tested, please add tests.
  • Ensure your code lints and the test suite passes (yarn lint) & (yarn test).

Follow up to #13247

@Lms24 Lms24 closed this Sep 18, 2024
@Lms24 Lms24 reopened this Sep 18, 2024
@Lms24
Copy link
Member

Lms24 commented Sep 18, 2024

Hi @gurpreetatwal thanks for opening this PR! I'm sorry for the late review. Looks fine to me. Since we're only extending the previous type I this doesn't classify as a breaking change so we can merge it in.

(heads-up: Just assigning myself to track internally that I'm reviewing it)

@Lms24
Copy link
Member

Lms24 commented Sep 18, 2024

I see this PR is still in draft - did you want to add something to still?

@gurpreetatwal
Copy link
Contributor Author

Hi @Lms24! Apologies for the delayed response on my end, we're good to merge!

I had it in draft status because I was trying to get the test suite to run on my computer but wasn't able to and hadn't yet had the time to figure out if it was a code issue or a just dev set up issues.

…hers

SvelteKit narrows the type of event.params based on ParamMatchers that are defined in the path, by making the function generic we can respect the narrowed type
@gurpreetatwal gurpreetatwal marked this pull request as ready for review October 8, 2024 20:42
@Lms24
Copy link
Member

Lms24 commented Oct 9, 2024

Thanks for getting back to me! Will let CI run again on the changes and then merge it.

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.

2 participants