Skip to content

Commit

Permalink
Code cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
akadlec committed May 23, 2021
1 parent a33b24f commit a294fcc
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 28 deletions.
8 changes: 4 additions & 4 deletions README.md
Expand Up @@ -12,17 +12,17 @@ Implementation of CRUD system into [Doctrine3](https://github.com/doctrine/orm)

## Installation

The best way to install ipub/doctrine-crud is using [Composer](http://getcomposer.org/):
The best way to install **ipub/doctrine-crud** is using [Composer](http://getcomposer.org/):

```sh
$ composer require ipub/doctrine-crud
composer require ipub/doctrine-crud
```

After that you have to register extension in config.neon.
After that, you have to register extension in config.neon.

```neon
extensions:
doctrineCrud: IPub\DoctrineCrud\DI\DoctrineCrudExtension
doctrineCrud: IPub\DoctrineCrud\DI\DoctrineCrudExtension
```

## Documentation
Expand Down
4 changes: 2 additions & 2 deletions docs/en/index.md
Expand Up @@ -8,10 +8,10 @@ This Doctrine CRUD extension brings you easier way how to **C**reate, **R**ead,
## Installation

The best way to install ipub/doctrine is using [Composer](http://getcomposer.org/):
The best way to install **ipub/doctrine-crud** is using [Composer](http://getcomposer.org/):

```sh
$ composer require ipub/doctrine-crud
composer require ipub/doctrine-crud
```

After that you have to register extension in config.neon.
Expand Down
3 changes: 0 additions & 3 deletions phpstan.neon
@@ -1,5 +1,2 @@
parameters:
level: max
stubFiles:
- tests/PHPStan/stubs/Doctrine/ORM/Query.php
- tests/PHPStan/stubs/Doctrine/ORM/QueryBuilder.php
8 changes: 5 additions & 3 deletions src/Mapping/EntityMapper.php
Expand Up @@ -91,7 +91,7 @@ public function fillEntity(Utils\ArrayHash $values, Entities\IEntity $entity, bo
throw new Exceptions\InvalidStateException(sprintf('Entity manager for entity %s could not be loaded', $entityClass));
}

/** @var ORM\Mapping\ClassMetadata $classMetadata */
/** @phpstan-var ORM\Mapping\ClassMetadataInfo<object> $classMetadata */
$classMetadata = $entityClassManager->getClassMetadata($entityClass);

$reflectionProperties = [];
Expand Down Expand Up @@ -384,15 +384,17 @@ private function findAttributeName(Entities\IEntity $entity, string $className):
}

/**
* @param ORM\Mapping\ClassMetadata $classMetadata
* @param ORM\Mapping\ClassMetadataInfo $classMetadata
* @param Entities\IEntity $entity
* @param string $field
* @param mixed $value
*
* @return void
*
* @phpstan-param ORM\Mapping\ClassMetadataInfo<object> $classMetadata
*/
private function setFieldValue(
ORM\Mapping\ClassMetadata $classMetadata,
ORM\Mapping\ClassMetadataInfo $classMetadata,
Entities\IEntity $entity,
string $field,
$value
Expand Down
8 changes: 0 additions & 8 deletions tests/PHPStan/stubs/Doctrine/ORM/Query.php

This file was deleted.

8 changes: 0 additions & 8 deletions tests/PHPStan/stubs/Doctrine/ORM/QueryBuilder.php

This file was deleted.

0 comments on commit a294fcc

Please sign in to comment.