Indents with chain method call
Consider the following example:
class Response
{
public function code(): Code
{
return new Code();
}
}
class Code
{
public function isSuccessful() { }
}
Right now if we chain method call, the ident will be the following:
(new Response())
->code()
->isSuccessful()
;
The desired behavior for me is the autodetection of the return type. If the return type is a different object (not the self) then make additional ident, like this:
(new Response())
->code()
->isSuccessful()
;
Is there a way enforce that code style in my project? I haven't found the necessary option in the Code Style settings.
Please sign in to leave a comment.