Repository navigation
fix: fix crash when message.fix is nullish - #19168
Conversation
✅ Deploy Preview for docs-eslint ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
|
Thanks for the PR. It's not clear from the changes or from you repo how to reproduce this error. Can you please provide some reproduction steps? |
message.fix is nilmessage.fix is nullish
|
@ntnyq friendly ping. Can you answer my questions above? Thanks. |
Sorry for reply late. I created a new repo with fewer code https://github.com/ntnyq-dev/repro-eslint-fix. And added the repro steps in README. |
|
As I tested. When call It cause the crash. |
|
Thanks, I can reproduce the crash. For the record, here's what I see in the console: In the future, please be sure to open an issue first when reporting a bug so you can provide all of the info we need. |
nzakas
left a comment
There was a problem hiding this comment.
Just want to clean up the test names a bit, but otherwise looks good.
|
Got it and Resolved. Thanks for your advice. |
|
Don't know why Browser Test failed in CI. I tried run it in local and it went well. |
|
Don't worry about the browser test. It's pretty flaky lately. |
nzakas
left a comment
There was a problem hiding this comment.
LGTM. Would like another review before merging.
|
I think this is rather a bug in the processor. It gets a lint message without but returns message with Lint messages normally don't have the |
Prerequisites checklist
What is the purpose of this pull request? (put an "X" next to an item)
[ ] Documentation update
[x] Bug fix (template)
[ ] New rule (template)
[ ] Changes an existing rule (template)
[ ] Add autofix to a rule
[ ] Add a CLI option
[ ] Add something to the core
[ ] Other, please explain:
No need for providing the template. So I skipped it.
What changes did you make? (Give an overview)
This PR adds a simple check in
linter.source-code-fixerincasingmessage.fixequals tonullorundefinedwhich might cause the linter throw.Is there anything you'd like reviewers to focus on?
There is a reproduction repo https://github.com/pany-ang/issue-eslint-config.
Or you can just remove the check, run the tests added.