Skip to content

Commit

Permalink
[Rector] Applied all Symfony 5.x rectors to the production codebase (#73
Browse files Browse the repository at this point in the history
)

Applied rules:
 * AddReturnTypeDeclarationRector
  • Loading branch information
alongosz authored Aug 9, 2024
1 parent 02b4f19 commit bb3f87a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/bundle/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function __construct($rootNodeName)
$this->rootNodeName = $rootNodeName;
}

public function getConfigTreeBuilder()
public function getConfigTreeBuilder(): TreeBuilder
{
$treeBuilder = new TreeBuilder($this->rootNodeName);

Expand Down
5 changes: 3 additions & 2 deletions src/bundle/DependencyInjection/IbexaSolrExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
use Ibexa\Solr\Gateway\DistributionStrategy\CloudDistributionStrategy;
use Ibexa\Solr\Gateway\UpdateSerializerInterface;
use Ibexa\Solr\Handler;
use Symfony\Component\Config\Definition\ConfigurationInterface;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\DependencyInjection\ChildDefinition;
use Symfony\Component\DependencyInjection\ContainerBuilder;
Expand Down Expand Up @@ -91,7 +92,7 @@ class IbexaSolrExtension extends Extension

public const GATEWAY_UPDATE_SERIALIZER_TAG = 'ibexa.solr.gateway.serializer.update';

public function getAlias()
public function getAlias(): string
{
return 'ibexa_solr';
}
Expand Down Expand Up @@ -292,7 +293,7 @@ protected function defineEndpoint(ContainerBuilder $container, $alias, $params)
);
}

public function getConfiguration(array $config, ContainerBuilder $container)
public function getConfiguration(array $config, ContainerBuilder $container): ?ConfigurationInterface
{
return new Configuration($this->getAlias());
}
Expand Down
3 changes: 2 additions & 1 deletion src/bundle/IbexaSolrBundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
use Ibexa\Solr\Container\Compiler\FieldMapperPass;
use Ibexa\Solr\Container\Compiler\GatewayRegistryPass;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Extension\ExtensionInterface;
use Symfony\Component\HttpKernel\Bundle\Bundle;

class IbexaSolrBundle extends Bundle
Expand All @@ -37,7 +38,7 @@ public function build(ContainerBuilder $container)
$container->addCompilerPass(new CoreFilterRegistryPass());
}

public function getContainerExtension()
public function getContainerExtension(): ?ExtensionInterface
{
if (!isset($this->extension)) {
$this->extension = new IbexaSolrExtension();
Expand Down

0 comments on commit bb3f87a

Please sign in to comment.