Skip to content

Commit bc511bb

Browse files
authored
[TASK] Disable PHP CS Fixer statement_indentation rule (#798)
Unfortunately, this has been broken for comments preceding a `case` within a `switch` since PHP CS Fixer version 3.9.1. See - PHP-CS-Fixer/PHP-CS-Fixer#6572 - PHP-CS-Fixer/PHP-CS-Fixer#6490 - PHP-CS-Fixer/PHP-CS-Fixer#6490 (comment) - PHP-CS-Fixer/PHP-CS-Fixer#7624 A configuration option `stick_comment_to_next_continuous_control_statement` was added, but this has not yet been extended to cover `case` within a `switch`. So, for the time being, we cannot use this rule if we want to comment `case`s within a `swtich`. Co-authored-by: Jake Hotson <jake.github@qzdesign.co.uk>
1 parent f67aa12 commit bc511bb

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

config/php-cs-fixer.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,8 @@
9696
// string notation
9797
'single_quote' => true,
9898
'string_implicit_backslashes' => ['single_quoted' => 'escape'],
99+
100+
// whitespace
101+
'statement_indentation' => false,
99102
]
100103
);

0 commit comments

Comments
 (0)