-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Clean up CodeFactor style issues coming in commits for the last month #10591
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
Clean up CodeFactor style issues coming in commits for the last month #10591
Conversation
|
@iSazonov Can you clean up the title to say what you changed. The fact that the last commit caused issues should go in the PR context |
|
@TravisEz13 I hope I addressed your request, otherwise please do this for me. |
| else if (rawIntValue == 0) | ||
| { | ||
| propertyValue = false; | ||
| } |
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.
This is a fairly straightforward bit of logic; perhaps it might be a bit tidier here using ternary syntax?
propertyValue = rawIntValue == 1 ? true : false;Unless there's actually a third possible outcome here, but that seems like something that isn't handled here anyway. 🙂
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.
@vexx32 Thanks! You are right but no code changes is in the PR, only formatting. I don't want second review round in the simple style PR.
| else | ||
| { | ||
| return true; | ||
| } |
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.
We could just return the result of the boolean expression in the if statement here if we invert the condition. 🙂
return peekResult != -1;|
🎉 Handy links: |
PR Summary
Fix style issues in commits for last month. Only formatting changes, no code changes.
PR Context
Most of merged commits has no style issues in CodeFactor reports but sometimes we pass some style issues to speed up code review and focus on functional changes so we have to fix them from time to time.
CodeFactor statistics says that we fix up to 780 style issues in last month and add 98 new ones. Good trend!
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:or[ WIP ]to the beginning of the title (theWIPbot will keep its status check atPendingwhile the prefix is present) and remove the prefix when the PR is ready.