From 6465a639fa69cc33e32c23a737ed0e606bf51cb1 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Fri, 11 Aug 2023 13:26:27 +0000 Subject: [PATCH] [rector] Rector fixes --- src/Builder/Capacity/Extractor/ListPerPage.php | 2 +- src/Builder/Capacity/Loader/Upsert.php | 4 ++-- src/Builder/Capacity/Lookup/All.php | 2 +- src/Builder/Capacity/Lookup/ListPerPage.php | 2 +- src/Builder/Client.php | 2 +- src/Builder/ConditionalLookup.php | 10 +++++----- src/Builder/Extractor.php | 8 ++++---- src/Builder/Loader.php | 8 ++++---- src/Builder/Lookup.php | 10 +++++----- 9 files changed, 24 insertions(+), 24 deletions(-) diff --git a/src/Builder/Capacity/Extractor/ListPerPage.php b/src/Builder/Capacity/Extractor/ListPerPage.php index 725019f..f319209 100644 --- a/src/Builder/Capacity/Extractor/ListPerPage.php +++ b/src/Builder/Capacity/Extractor/ListPerPage.php @@ -88,7 +88,7 @@ public function getNode(): Node new Node\Stmt\Expression( expr: new Node\Expr\Yield_( value: new Node\Expr\New_( - class: new Node\Name\FullyQualified(name: 'Kiboko\\Component\\Bucket\\AcceptanceResultBucket'), + class: new Node\Name\FullyQualified(name: \Kiboko\Component\Bucket\AcceptanceResultBucket::class), args: [ new Node\Arg( new Node\Expr\Variable('item') diff --git a/src/Builder/Capacity/Loader/Upsert.php b/src/Builder/Capacity/Loader/Upsert.php index 5f7dd55..da32f5b 100644 --- a/src/Builder/Capacity/Loader/Upsert.php +++ b/src/Builder/Capacity/Loader/Upsert.php @@ -94,7 +94,7 @@ public function getNode(): Node var: new Node\Expr\Variable('line'), expr: new Node\Expr\Yield_( value: new Node\Expr\New_( - class: new Node\Name\FullyQualified(name: 'Kiboko\\Component\\Bucket\\AcceptanceResultBucket'), + class: new Node\Name\FullyQualified(name: \Kiboko\Component\Bucket\AcceptanceResultBucket::class), args: [ new Node\Arg( value: new Node\Expr\Variable('line'), @@ -109,7 +109,7 @@ class: new Node\Name\FullyQualified(name: 'Kiboko\\Component\\Bucket\\Acceptance new Node\Stmt\Catch_( types: [ new Node\Name\FullyQualified( - name: 'Akeneo\\Pim\\ApiClient\\Exception\\HttpException', + name: \Akeneo\Pim\ApiClient\Exception\HttpException::class, ), ], var: new Node\Expr\Variable('exception'), diff --git a/src/Builder/Capacity/Lookup/All.php b/src/Builder/Capacity/Lookup/All.php index 12ec5e5..4e3be7e 100644 --- a/src/Builder/Capacity/Lookup/All.php +++ b/src/Builder/Capacity/Lookup/All.php @@ -115,7 +115,7 @@ public function getNode(): Node catches: [ new Node\Stmt\Catch_( types: [ - new Node\Name\FullyQualified('Akeneo\Pim\ApiClient\Exception\HttpException'), + new Node\Name\FullyQualified(\Akeneo\Pim\ApiClient\Exception\HttpException::class), ], var: new Node\Expr\Variable('exception'), stmts: [ diff --git a/src/Builder/Capacity/Lookup/ListPerPage.php b/src/Builder/Capacity/Lookup/ListPerPage.php index 8e2ed4f..47df875 100644 --- a/src/Builder/Capacity/Lookup/ListPerPage.php +++ b/src/Builder/Capacity/Lookup/ListPerPage.php @@ -115,7 +115,7 @@ public function getNode(): Node catches: [ new Node\Stmt\Catch_( types: [ - new Node\Name\FullyQualified('Akeneo\Pim\ApiClient\Exception\HttpException'), + new Node\Name\FullyQualified(\Akeneo\Pim\ApiClient\Exception\HttpException::class), ], var: new Node\Expr\Variable('exception'), stmts: [ diff --git a/src/Builder/Client.php b/src/Builder/Client.php index 0afde3f..a143a3f 100644 --- a/src/Builder/Client.php +++ b/src/Builder/Client.php @@ -70,7 +70,7 @@ public function withFileSystem(Node\Expr $fileSystem): self public function getNode(): Node\Expr\MethodCall { $instance = new Node\Expr\New_( - new Node\Name\FullyQualified('Akeneo\\Pim\\ApiClient\\AkeneoPimClientBuilder'), + new Node\Name\FullyQualified(\Akeneo\Pim\ApiClient\AkeneoPimClientBuilder::class), [ new Node\Arg($this->baseUrl), ], diff --git a/src/Builder/ConditionalLookup.php b/src/Builder/ConditionalLookup.php index 105e762..3b6bc65 100644 --- a/src/Builder/ConditionalLookup.php +++ b/src/Builder/ConditionalLookup.php @@ -74,7 +74,7 @@ private function compileAllAlternatives(): Node expr: new Node\Expr\Assign( var: new Node\Expr\Variable('bucket'), expr: new Node\Expr\New_( - new Node\Name\FullyQualified('Kiboko\Component\Bucket\ComplexResultBucket') + new Node\Name\FullyQualified(\Kiboko\Component\Bucket\ComplexResultBucket::class) ) ) ), @@ -126,7 +126,7 @@ class: new Node\Stmt\Class_( name: null, subNodes: [ 'implements' => [ - new Node\Name\FullyQualified(name: 'Kiboko\\Contract\\Pipeline\\TransformerInterface'), + new Node\Name\FullyQualified(name: \Kiboko\Contract\Pipeline\TransformerInterface::class), ], 'stmts' => [ new Node\Stmt\ClassMethod( @@ -136,12 +136,12 @@ class: new Node\Stmt\Class_( 'params' => [ new Node\Param( var: new Node\Expr\Variable('client'), - type: new Node\Name\FullyQualified(name: 'Akeneo\\Pim\\ApiClient\\AkeneoPimClientInterface'), + type: new Node\Name\FullyQualified(name: \Akeneo\Pim\ApiClient\AkeneoPimClientInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), new Node\Param( var: new Node\Expr\Variable('logger'), - type: new Node\Name\FullyQualified(name: 'Psr\\Log\\LoggerInterface'), + type: new Node\Name\FullyQualified(name: \Psr\Log\LoggerInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), ], @@ -170,7 +170,7 @@ class: new Node\Stmt\Class_( ), args: [ new Node\Arg(value: $this->client), - new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified('Psr\\Log\\NullLogger'))), + new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified(\Psr\Log\NullLogger::class))), ], ); } diff --git a/src/Builder/Extractor.php b/src/Builder/Extractor.php index bc3365f..8651637 100644 --- a/src/Builder/Extractor.php +++ b/src/Builder/Extractor.php @@ -49,7 +49,7 @@ class: new Node\Stmt\Class_( name: null, subNodes: [ 'implements' => [ - new Node\Name\FullyQualified(name: 'Kiboko\\Contract\\Pipeline\\ExtractorInterface'), + new Node\Name\FullyQualified(name: \Kiboko\Contract\Pipeline\ExtractorInterface::class), ], 'stmts' => [ new Node\Stmt\ClassMethod( @@ -59,12 +59,12 @@ class: new Node\Stmt\Class_( 'params' => [ new Node\Param( var: new Node\Expr\Variable('client'), - type: new Node\Name\FullyQualified(name: 'Akeneo\\Pim\\ApiClient\\AkeneoPimClientInterface'), + type: new Node\Name\FullyQualified(name: \Akeneo\Pim\ApiClient\AkeneoPimClientInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), new Node\Param( var: new Node\Expr\Variable('logger'), - type: new Node\Name\FullyQualified(name: 'Psr\\Log\\LoggerInterface'), + type: new Node\Name\FullyQualified(name: \Psr\Log\LoggerInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), ], @@ -215,7 +215,7 @@ class: new Node\Stmt\Class_( ), args: [ new Node\Arg(value: $this->client), - new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified('Psr\\Log\\NullLogger'))), + new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified(\Psr\Log\NullLogger::class))), ], ); } diff --git a/src/Builder/Loader.php b/src/Builder/Loader.php index 64d9cf2..d5d4eb8 100644 --- a/src/Builder/Loader.php +++ b/src/Builder/Loader.php @@ -49,7 +49,7 @@ class: new Node\Stmt\Class_( name: null, subNodes: [ 'implements' => [ - new Node\Name\FullyQualified(name: 'Kiboko\\Contract\\Pipeline\\LoaderInterface'), + new Node\Name\FullyQualified(name: \Kiboko\Contract\Pipeline\LoaderInterface::class), ], 'stmts' => [ new Node\Stmt\ClassMethod( @@ -59,12 +59,12 @@ class: new Node\Stmt\Class_( 'params' => [ new Node\Param( var: new Node\Expr\Variable('client'), - type: new Node\Name\FullyQualified(name: 'Akeneo\\Pim\\ApiClient\\AkeneoPimClientInterface'), + type: new Node\Name\FullyQualified(name: \Akeneo\Pim\ApiClient\AkeneoPimClientInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), new Node\Param( var: new Node\Expr\Variable('logger'), - type: new Node\Name\FullyQualified(name: 'Psr\\Log\\LoggerInterface'), + type: new Node\Name\FullyQualified(name: \Psr\Log\LoggerInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), ], @@ -136,7 +136,7 @@ class: new Node\Stmt\Class_( ), args: [ new Node\Arg(value: $this->client), - new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified('Psr\\Log\\NullLogger'))), + new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified(\Psr\Log\NullLogger::class))), ], ); } diff --git a/src/Builder/Lookup.php b/src/Builder/Lookup.php index f659f1c..bd3a004 100644 --- a/src/Builder/Lookup.php +++ b/src/Builder/Lookup.php @@ -61,7 +61,7 @@ class: new Node\Stmt\Class_( name: null, subNodes: [ 'implements' => [ - new Node\Name\FullyQualified(name: 'Kiboko\\Contract\\Pipeline\\TransformerInterface'), + new Node\Name\FullyQualified(name: \Kiboko\Contract\Pipeline\TransformerInterface::class), ], 'stmts' => [ new Node\Stmt\ClassMethod( @@ -71,12 +71,12 @@ class: new Node\Stmt\Class_( 'params' => [ new Node\Param( var: new Node\Expr\Variable('client'), - type: new Node\Name\FullyQualified(name: 'Akeneo\\Pim\\ApiClient\\AkeneoPimClientInterface'), + type: new Node\Name\FullyQualified(name: \Akeneo\Pim\ApiClient\AkeneoPimClientInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), new Node\Param( var: new Node\Expr\Variable('logger'), - type: new Node\Name\FullyQualified(name: 'Psr\\Log\\LoggerInterface'), + type: new Node\Name\FullyQualified(name: \Psr\Log\LoggerInterface::class), flags: Node\Stmt\Class_::MODIFIER_PUBLIC, ), ], @@ -107,7 +107,7 @@ class: new Node\Stmt\Class_( expr: new Node\Expr\Assign( var: new Node\Expr\Variable('bucket'), expr: new Node\Expr\New_( - new Node\Name\FullyQualified('Kiboko\Component\Bucket\ComplexResultBucket') + new Node\Name\FullyQualified(\Kiboko\Component\Bucket\ComplexResultBucket::class) ) ) ), @@ -122,7 +122,7 @@ class: new Node\Stmt\Class_( ), args: [ new Node\Arg(value: $this->client), - new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified('Psr\\Log\\NullLogger'))), + new Node\Arg(value: $this->logger ?? new Node\Expr\New_(new Node\Name\FullyQualified(\Psr\Log\NullLogger::class))), ], ); }