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

update errors cause param type #150

Merged
merged 2 commits into from
Aug 14, 2024
Merged

Conversation

CatchMe2
Copy link
Collaborator

@CatchMe2 CatchMe2 commented Aug 14, 2024

Changes

  • change Internal and Public error cause type to unknown
  • add generic for PublicError (to be consistent with InternalError) - it will be breaking for any `if (err instanceof
  • update Readme with cause param

Migration guide

Any instanceof check for PublicNonRecoverableError has to be modified (applies only if isPublicNonRecoverableError wasn't used). Please change:

if (err instanceof PublicNonRecoverableError) { ... }

into

if (isPublicNonRecoverableError(err)) { ... }

Checklist

  • Apply one of following labels; major, minor, patch or skip-release
  • I've updated the documentation, or no changes were necessary
  • I've updated the tests, or no changes were necessary

@CatchMe2 CatchMe2 merged commit 8db1915 into main Aug 14, 2024
5 checks passed
@CatchMe2 CatchMe2 deleted the update-errors-cause-param-types branch August 14, 2024 12:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants