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(eslint-plugin): [prefer-optional-chain] handle binary expressions in negated or #5992

Conversation

omril1
Copy link
Contributor

@omril1 omril1 commented Nov 15, 2022

PR Checklist

Overview

I'm not sure why the default switch case is to throw instead of ignoring the code 😢
The issue was not yet triaged but I opened a PR just in case

@nx-cloud
Copy link

nx-cloud bot commented Nov 15, 2022

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 22be168. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 46 targets

Sent with 💌 from NxCloud.

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @omril1!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint.

@netlify
Copy link

netlify bot commented Nov 15, 2022

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit 22be168
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/6373d648e705d00008af7c6e
😎 Deploy Preview https://deploy-preview-5992--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great in general, thanks for sending this in so quickly! Just requesting changes for a little code simplification please. 🎉

packages/eslint-plugin/src/rules/prefer-optional-chain.ts Outdated Show resolved Hide resolved
@JoshuaKGoldberg JoshuaKGoldberg changed the title fix/issue5991-fix-prefer-optional-chain-BinaryExpression-in-negated-or fix(eslint-plugin): [prefer-optional-chain] handle binary expressions in negated or Nov 15, 2022
@JoshuaKGoldberg JoshuaKGoldberg added the awaiting response Issues waiting for a reply from the OP or another party label Nov 15, 2022
Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks!

@JoshuaKGoldberg JoshuaKGoldberg merged commit 2778ff0 into typescript-eslint:main Nov 16, 2022
@omril1 omril1 deleted the fix/issue5991-fix-prefer-optional-chain-BinaryExpression-in-negated-or branch November 16, 2022 04:02
@RobYed
Copy link

RobYed commented Nov 17, 2022

@omril1 Thanks for the quick fix!

@JoshuaKGoldberg Do you have an estimate of when this fix will be released? My project is also affected by this issue, thus looking forward to the next release.

@RobYed
Copy link

RobYed commented Nov 17, 2022

@bradzacher Thanks! I must have been blind! 🙈

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 25, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
awaiting response Issues waiting for a reply from the OP or another party
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: [prefer-optional-chain] Unexpected member property type: Identifier
4 participants