Skip to content

Commit

Permalink
minor #49896 Apply no_null_property_initialization PHP-CS-Fixer rule …
Browse files Browse the repository at this point in the history
…(yguedidi)

This PR was merged into the 6.3 branch.

Discussion
----------

Apply no_null_property_initialization PHP-CS-Fixer rule

| Q             | A
| ------------- | ---
| Branch?       | 6.3
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

After a discussion with `@stof`, this rule should be part of the ``@Symfony`` PHP-CS-Fixer ruleset.
This PR apply the rule on the Symfony code base.
see PHP-CS-Fixer/PHP-CS-Fixer#6876 for the PR on PHP-CS-Fixer

Commits
-------

2320c2a906 Apply no_null_property_initialization PHP-CS-Fixer rule
  • Loading branch information
nicolas-grekas committed Apr 3, 2023
2 parents 5bfe124 + d51e55d commit e047c78
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Mapping/Loader/YamlFileLoader.php
Expand Up @@ -29,7 +29,7 @@ class YamlFileLoader extends FileLoader
*
* @var array
*/
protected $classes = null;
protected $classes;

public function __construct(string $file)
{
Expand Down
2 changes: 1 addition & 1 deletion Tests/Mapping/Loader/StaticMethodLoaderTest.php
Expand Up @@ -119,7 +119,7 @@ public static function loadMetadata(ClassMetadata $metadata)

class StaticLoaderEntity
{
public static $invokedWith = null;
public static $invokedWith;

public static function loadMetadata(ClassMetadata $metadata)
{
Expand Down

0 comments on commit e047c78

Please sign in to comment.