Hi guys,
Sorry that this is not an actual bug, but are there any pre-existing sniffs or configurations that allows for the following (or know how to add it in)
array_filter($someArray, function () {
return true;
});
$cake = 'yes please';
to prevent
array_filter($someArray, function () {
return true;
});
$cake = 'yes please';
getSomething()
{
$something = 'something';
return $something;
}
or
getSomething()
{
return 'something';
}
rather than
getSomething()
{
$something = 'something';
return $something;
}
Thanks :)
blank_line_before_returnHi!
We've blank_line_before_return (on master there is blank_line_before_statement which will give even more options). We do not have a fixer for the last case (there is/was a WIP https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/1853 for it).
For the first we could add a new option to blank_line_before_statement.
Let us know if you can help, all the suggestions you made seem like a nice extension to me :)
@SpacePossum , but what option would that be?
put a blank line above if there is a lambda param in previous statement ?
here, in example, it's just a tap method call...
Thanks for the heads up, I'll have a look around for info regarding the blank_line_before_return :)
I would love to help, however I've already nosed around the source code and to be honest, its insane ha, I've no idea how you guys know whats going on in there, way out of my depth!
nah, who claimed we do? :P
that's why we have so many tests
Hi.
I'd like to see blank_line_after_statement as well.
@gruz, sadly, it's impossible for us to implement all the requests. Maybe you could help on it and propose a PR ?
Most helpful comment
nah, who claimed we do? :P
that's why we have so many tests