Remove blank lines inside functions/methods #7306
-
Hello! I would like to know if there is a rule to remove blank lines within functions and methods. For example: class Foo
{
public function makeFoo($foo)
{
echo 'foo'; // next line must be removed
if ($foo) {
return 1;
} // next lines must be removed
return 1;
}
} Thank you very much! |
Beta Was this translation helpful? Give feedback.
Answered by
Wirone
Sep 18, 2023
Replies: 1 comment 4 replies
-
No, we currently don't provide such ability. With |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ExcessiveMethodLength
can be configured withignore-whitespace=true
(this should be default IMHO). Also, I don't agree with Yegor's article, it's totally subjective - personally I am not comfortable with the condensed code, without empty lines. Anyway, we don't have such fixer currently and it's rather not possible that it will be available anytime soon.