Skip to content

Commit

Permalink
Replace deprecated no_blank_lines_before_namespace and `single_blan…
Browse files Browse the repository at this point in the history
…k_line_before_namespace` rules
  • Loading branch information
jeromegamez committed Jun 20, 2023
1 parent 3d48893 commit e3a7b62
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

## [Unreleased]

* Replaced deprecated `no_blank_lines_before_namespace` and `single_blank_line_before_namespace` rules with
`blank_lines_before_namespace`

## [2.1.0] - 2023-05-18

* Changed `php_unit_test_annotation` style from `prefix` to `annotation`
Expand Down
6 changes: 4 additions & 2 deletions src/RuleSet/CommonRules.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ protected function commonRules(): array
],
],
'blank_line_between_import_groups' => true,
'blank_lines_before_namespace' => [
'min_line_breaks' => 2,
'max_line_breaks' => 2,
],
'cast_spaces' => [
'space' => 'single',
],
Expand Down Expand Up @@ -254,7 +258,6 @@ protected function commonRules(): array
'no_binary_string' => true,
'no_blank_lines_after_class_opening' => true,
'no_blank_lines_after_phpdoc' => true,
'no_blank_lines_before_namespace' => false,
'no_break_comment' => [
'comment_text' => 'no break',
],
Expand Down Expand Up @@ -626,7 +629,6 @@ protected function commonRules(): array
'simplified_if_return' => false,
'simplified_null_return' => true,
'single_blank_line_at_eof' => true,
'single_blank_line_before_namespace' => true,
'single_class_element_per_statement' => [
'elements' => [
'const',
Expand Down

0 comments on commit e3a7b62

Please sign in to comment.