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
Lint/ElseLayout
does not warn when else contains only one line code
#10130
Comments
Layout/ElseLayout
does not warn when else contains only one line code
Sorry I misunderstood the issue, I was looking at the wrong cop and didn't realize we had both |
Layout/ElseLayout
does not warn when else contains only one line codeLayout/ElseAlignment
does not warn when else contains only one line code
Layout/ElseAlignment
does not warn when else contains only one line codeLayout/ElseLayout
does not warn when else contains only one line code
Layout/ElseLayout
does not warn when else contains only one line codeLint/ElseLayout
does not warn when else contains only one line code
…`else` with only a single line.
[Fix #10130] Update `Lint/ElseLayout` to be able to handle an `else` with only a single line
That issue was fixed really fast. Thank you! |
Expected behavior
Warn when having an expression on the same line as the
else
keyword.Actual behavior
Does not warn when having an expression on the same line as the
else
keyword and else statement contains only one line code.Steps to reproduce the problem
Write one line code on the same line with else statement. Example:
RuboCop version
The text was updated successfully, but these errors were encountered: