Skip to content

Commit

Permalink
Annotations: unlock doctrine/annotations v2 [closes #196]
Browse files Browse the repository at this point in the history
  • Loading branch information
f3l1x committed Dec 1, 2023
1 parent 122192e commit 7a7ea09
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 8 deletions.
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"contributte/psr7-http-message": "^0.9.0 || ^0.10.0",
"contributte/middlewares": "^0.11.0",
"contributte/openapi": "^0.1.0",
"doctrine/annotations": "^1.14.3",
"doctrine/annotations": "^1.14.3 || ^2.0.0",
"koriym/attributes": "^1.0.5",
"nette/utils": "^4.0.0"
},
Expand All @@ -37,7 +37,6 @@
"nette/application": "^3.1.4",
"nette/di": "^3.1.8",
"nette/http": "^3.2.3",
"nettrine/annotations": "^0.7.0",
"psr/log": "^2.0.0 || ^3.0.0",
"symfony/console": "^6.4.0 || ^7.0.0",
"symfony/validator": "^6.4.0 || ^7.0.0",
Expand Down
3 changes: 0 additions & 3 deletions phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ parameters:
checkGenericClassInNonGenericObjectType: false

ignoreErrors:
# deprecated with no replacement until 2.0.0
- '#^Call to deprecated method registerUniqueLoader\(\) of class Doctrine\\Common\\Annotations\\AnnotationRegistry.+#'

# Intended property access - required for reflection
- '#^Variable property access on (\$this|static)\(Apitte\\Core\\Mapping\\(Request|Response)\\BasicEntity\)\.$#'
- '#^Variable property access on Apitte\\Core\\Mapping\\Request\\BasicEntity\.$#'
Expand Down
3 changes: 0 additions & 3 deletions src/Core/DI/LoaderFactory/DualReaderFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
namespace Apitte\Core\DI\LoaderFactory;

use Doctrine\Common\Annotations\AnnotationReader;
use Doctrine\Common\Annotations\AnnotationRegistry;
use Doctrine\Common\Annotations\Reader;
use Koriym\Attributes\AttributeReader;
use Koriym\Attributes\DualReader;
Expand All @@ -17,8 +16,6 @@ class DualReaderFactory
public function create(): Reader
{
$annotationReader = new AnnotationReader();
AnnotationRegistry::registerUniqueLoader('class_exists');

$attributeReader = new AttributeReader();

return new DualReader($annotationReader, $attributeReader);
Expand Down

0 comments on commit 7a7ea09

Please sign in to comment.