We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
if
unkown
null
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
if unkown null
typescript@next
This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________
Playground link with relevant code
declare const error: unknown if (error) { throw typeof error === 'object' && 'message' in error ? Object.assign(new Error(), error) : error }
Object is possibly 'null'.
No error, if (error) has already ensured error will never be null.
if (error)
error
The text was updated successfully, but these errors were encountered:
Duplicate of #28131
Sorry, something went wrong.
Thanks.
No branches or pull requests
Bug Report
π Search Terms
if unkown null
π Version & Regression Information
typescript@next
This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________
β― Playground Link
Playground link with relevant code
π» Code
π Actual behavior
π Expected behavior
No error,
if (error)
has already ensurederror
will never benull
.The text was updated successfully, but these errors were encountered: