-
Notifications
You must be signed in to change notification settings - Fork 141
Fix behavior when endColumn or endLine is null #1217
Conversation
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.
Seems like a worthwhile change, thanks. I believe the tests are failing due to a logic inversion, which I've suggested a fix to below.
Nice catch. I was wondering why the tests were failing on the version I was running in terminal but not the one in atom, must have missed that char when copying between. Should pass now 🤞 |
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.
Nice change, thanks for contributing!
Actually, one more thing before I merge this, do you think you could add a regression test, based on the results that the jsdoc plugin is giving? Then we'll be sure not to break this in the future. |
@mattlyons0 I haven't forgotten about this, just been busy. I'll try to review in the next few days. Thanks again. |
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.
Thanks for your help. Please git rebase master
to get in sync with the master branch. Verify everything still behaves as expected, and push the updated commit.
Looks like you are following a different commit format now, updated. |
🎉 This PR is included in version 8.5.2 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Fixes #1197, #1196, #1195, #1192
The JSDoc plugin returns
null
when there isn't a end column. The ESLint API docs specifically say the type ofendColumn
andendLine
are optional or must be anumber
, therefore it is probably more correct and safer to do that check instead of a undefined check: https://eslint.org/docs/developer-guide/working-with-plugins