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

Use optional chaining to catch null error codes in error.js #1054

Merged
merged 2 commits into from
Dec 18, 2024

Conversation

trbernstein
Copy link
Contributor

Starting a new vite project and selecting svelte-ts template results in an error, because code var in error.js is null. Optional chaining resolves this issue.

Starting a new vite project and selecting svelte-ts template results in an error, because `code` var in error.js is null. Optional chaining resolves this issue.
@trbernstein
Copy link
Contributor Author

Solves #1055.

@dominikg dominikg merged commit 47184d4 into sveltejs:main Dec 18, 2024
6 checks passed
@github-actions github-actions bot mentioned this pull request Dec 18, 2024
dominikg pushed a commit that referenced this pull request Dec 18, 2024
* Use optional chaining to catch null error codes in error.js

Starting a new vite project and selecting svelte-ts template results in an error, because `code` var in error.js is null. Optional chaining resolves this issue.

* chore: add changeset

---------

Co-authored-by: dominikg <[email protected]>
(cherry picked from commit 47184d4)
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