-
Notifications
You must be signed in to change notification settings - Fork 0
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
A poorly styled change #2
base: master
Are you sure you want to change the base?
Conversation
@@ -1,3 +1,7 @@ | |||
if x = 1 | |||
puts "This should trigger warnings!" | |||
end | |||
|
|||
if y = 3 |
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.
Useless assignment to variable - y
.
@@ -1,3 +1,7 @@ | |||
if x = 1 | |||
puts "This should trigger warnings!" | |||
end | |||
|
|||
if y = 3 |
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.
Use ==
if you meant to do a comparison or wrap the expression in parentheses to indicate you meant to assign in a condition.
@@ -1,3 +1,7 @@ | |||
if x = 1 | |||
puts "This should trigger warnings!" | |||
end | |||
|
|||
if y = 3 | |||
puts "This is a new change that should get a comment" |
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.
Prefer single-quoted strings when you don't need string interpolation or special symbols.
Pronto?