Skip to content

Commit da145ec

Browse files
authored
Merge pull request #10 from jeroenvandergulik/boyscout/fix-deprecation-errors
Remove deprecation errors
2 parents 8e618ec + 9223aeb commit da145ec

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

.php_cs.dist renamed to .php-cs-fixer.dist.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,13 @@
77
use PhpCsFixer\Finder;
88

99
$finder = Finder::create()
10-
->name('.php_cs.dist') // Fix this file as well
1110
->in(__DIR__);
1211

1312
$overrides = [
1413
'declare_strict_types' => true,
1514
];
1615

17-
return Config::create()
16+
return (new Config())
1817
->setFinder($finder)
1918
->setRiskyAllowed(true)
2019
->setRules(Rules::getForPhp71($overrides));

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ $config->setRules(Rules::getForPhp73());
2424

2525
### New to PHP-CS-Fixer
2626

27-
Place a file named `.php_cs.dist` that has following content in your project's root directory.
27+
Place a file named `.php-cs-fixer.dist.php` that has the following content in your project's root directory.
2828

2929
```php
3030
<?php
@@ -34,10 +34,9 @@ use PhpCsFixer\Config;
3434
use PhpCsFixer\Finder;
3535

3636
$finder = Finder::create()
37-
->name('.php_cs.dist') // Fix this file as well
3837
->in(__DIR__);
3938

40-
return Config::create()
39+
return (new Config())
4140
->setFinder($finder)
4241
->setRiskyAllowed(true)
4342
// use specific rules for your php version e.g.: getForPhp71, getForPhp72, getForPhp73

src/PhpCsFixer/Rules.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,6 @@ private static function getBaseRules(): array
7979
'increment_style' => [
8080
'style' => 'post',
8181
],
82-
'is_null' => [
83-
'use_yoda_style' => false,
84-
],
8582
'list_syntax' => [
8683
'syntax' => 'short',
8784
],

0 commit comments

Comments
 (0)