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: Remove autofixer for no-unsafe-negation #12157
Conversation
Hi @mdjermanovic, thanks for the PR. Is there a circumstance in which the user would legitimately want |
Most likely not :-) I think it's a policy to never modify behavior, I believe this is the only rule of all rules that have auto-fix that does that intentionally. |
Labeling as non-breaking enhancement for now. Feel free to relabel as needed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you!
What is the purpose of this pull request? (put an "X" next to item)
[X] Bug fix
This is a PR to remove the autofix feature from
no-unsafe-negation
, as it intentionally changes the runtime behavior of the code.Tell us about your environment
What parser (default, Babel-ESLint, etc.) are you using?
default
Please show your full configuration:
Configuration
What did you do? Please include the actual source code causing the issue.
What did you expect to happen?
Error, but not the auto-fix.
What actually happened? Please include the actual, raw output from ESLint.
What changes did you make? (Give an overview)
Removed the fixer.
Is there anything you'd like reviewers to focus on?
Is this is a non-breaking change?
Documentation is missing some important details, I'll fix that in another PR.