Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump PHPStan to level 2 when doing deprecations #267

Merged
merged 4 commits into from
Apr 29, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
always ignore Unsafe usage of new static()
  • Loading branch information
mglaman committed Apr 29, 2022
commit 94ba63cb0dbf69f24be0d9973b5c56e10a023a5a
9 changes: 4 additions & 5 deletions src/Command/CheckCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@ protected function execute(InputInterface $input, OutputInterface $output): int
'*/settings*.php',
'*/node_modules/*'
],
'ignoreErrors' => [],
'ignoreErrors' => [
'#Unsafe usage of new static\(\)#'
],
'drupal' => [
'drupal_root' => $this->drupalRoot,
]
Expand All @@ -157,10 +159,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int

if ($this->isAnalysisCheck) {
$configuration_data['parameters']['level'] = 6;

$ignored_analysis_errors = [
'#Unsafe usage of new static\(\)#'
];
$ignored_analysis_errors = [];
$configuration_data['parameters']['ignoreErrors'] = array_merge($ignored_analysis_errors, $configuration_data['parameters']['ignoreErrors']);
} else {
$configuration_data['parameters']['level'] = 2;
Expand Down