Skip to content

Commit 87f413d

Browse files
committed
Fix: Initialize and set Finder
1 parent 9b6eb3e commit 87f413d

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

.php-cs-fixer.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414
use Ergebnis\License;
1515
use Ergebnis\PhpCsFixer;
16+
use PhpCsFixer\Finder;
1617

1718
$license = License\Type\MIT::markdown(
1819
__DIR__ . '/LICENSE.md',
@@ -32,17 +33,17 @@
3233
'fully_qualified_strict_types' => false,
3334
]));
3435

35-
$config = PhpCsFixer\Config\Factory::fromRuleSet($ruleSet);
36-
37-
$config->getFinder()
36+
$finder = Finder::create()
3837
->exclude([
3938
'.build/',
4039
'.github/',
4140
'.note/',
4241
])
4342
->ignoreDotFiles(false)
4443
->in(__DIR__);
44+
$config = PhpCsFixer\Config\Factory::fromRuleSet($ruleSet);
4545

4646
$config->setCacheFile(__DIR__ . '/.build/php-cs-fixer/.php-cs-fixer.cache');
47+
$config->setFinder($finder);
4748

4849
return $config;

0 commit comments

Comments
 (0)