Skip to content

Commit

Permalink
More fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
phansys committed Sep 3, 2023
1 parent d499cae commit 3754da4
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/Mapping/Driver/AbstractAnnotationDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,10 @@ protected function isValidField($meta, $field)
* @param string $name the related object class name
*
* @return string related class name or empty string if does not exist
*
* @phpstan-param class-string|string $name
*
* @phpstan-return class-string|''
*/
protected function getRelatedClassName($metadata, $name)
{
Expand Down
12 changes: 10 additions & 2 deletions src/Mapping/Driver/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ public function setOriginalDriver($driver)
*
* @param string $file the mapping file to load
*
* @return array
* @return array<string, array<string, mixed>|object|null>
*
* @phpstan-return array<class-string, array<string, mixed>|object|null>
*/
abstract protected function _loadMappingFile($file);

Expand All @@ -112,7 +114,9 @@ abstract protected function _loadMappingFile($file);
*
* @param string $className
*
* @return array|object|null
* @return array<string, mixed>|object|null
*
* @phpstan-param class-string $className
*/
protected function _getMapping($className)
{
Expand Down Expand Up @@ -140,6 +144,10 @@ protected function _getMapping($className)
* @param string $name the related object class name
*
* @return string related class name or empty string if does not exist
*
* @phpstan-param class-string|string $name
*
* @phpstan-return class-string|''
*/
protected function getRelatedClassName($metadata, $name)
{
Expand Down
4 changes: 3 additions & 1 deletion src/Mapping/Event/AdapterInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,9 @@ public function getObjectState($uow, $object);
* @param ORMUnitOfWork|MongoDBUnitOfWork $uow The UnitOfWork as provided by the object manager
* @param object $object
*
* @return array
* @return array<string, array<int, mixed>|object>
*
* @phpstan-return array<string, array{0: mixed, 1: mixed}|object>
*/
public function getObjectChangeSet($uow, $object);

Expand Down

0 comments on commit 3754da4

Please sign in to comment.