Skip to content

Commit

Permalink
Merged branch '4.6'
Browse files Browse the repository at this point in the history
  • Loading branch information
alongosz committed Apr 18, 2024
2 parents 20cf5e1 + 65cf2fd commit 9a396e3
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 175 deletions.
5 changes: 0 additions & 5 deletions phpstan-baseline-7.4.neon
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,6 @@ parameters:
count: 1
path: src/bundle/Core/Imagine/PlaceholderProvider/RemoteProvider.php

-
message: "#^Parameter \\#1 \\$str of function trim expects string, string\\|false given\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#1 \\$fp of function fclose expects resource, resource\\|false given\\.$#"
count: 1
Expand Down
5 changes: 0 additions & 5 deletions phpstan-baseline-8.0.neon
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,6 @@ parameters:
count: 2
path: src/bundle/Core/URLChecker/Handler/HTTPHandler.php

-
message: "#^Parameter \\#1 \\$string of function trim expects string, string\\|false given\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#1 \\$stream of function fclose expects resource, resource\\|false given\\.$#"
count: 1
Expand Down
55 changes: 0 additions & 55 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -4140,66 +4140,11 @@ parameters:
count: 1
path: src/bundle/Debug/DependencyInjection/Compiler/DataCollectorPass.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\DependencyInjection\\\\IbexaDebugExtension\\:\\:load\\(\\) has no return type specified\\.$#"
count: 1
path: src/bundle/Debug/DependencyInjection/IbexaDebugExtension.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\DependencyInjection\\\\IbexaDebugExtension\\:\\:prepend\\(\\) has no return type specified\\.$#"
count: 1
path: src/bundle/Debug/DependencyInjection/IbexaDebugExtension.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\IbexaDebugBundle\\:\\:build\\(\\) has no return type specified\\.$#"
count: 1
path: src/bundle/Debug/IbexaDebugBundle.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\Twig\\\\DebugTemplate\\:\\:display\\(\\) has parameter \\$blocks with no value type specified in iterable type array\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\Twig\\\\DebugTemplate\\:\\:display\\(\\) has parameter \\$context with no value type specified in iterable type array\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\Twig\\\\DebugTemplate\\:\\:doDisplay\\(\\) has parameter \\$blocks with no value type specified in iterable type array\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Method Ibexa\\\\Bundle\\\\Debug\\\\Twig\\\\DebugTemplate\\:\\:doDisplay\\(\\) has parameter \\$context with no value type specified in iterable type array\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#1 \\$haystack of function stripos expects string, string\\|false\\|null given\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#1 \\$path of function dirname expects string, string\\|false given\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#1 \\$string of function substr expects string, string\\|false\\|null given\\.$#"
count: 2
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Parameter \\#3 \\$subject of function preg_replace expects array\\|string, string\\|false given\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Property Ibexa\\\\Bundle\\\\Debug\\\\Twig\\\\DebugTemplate\\:\\:\\$fileSystem has no type specified\\.$#"
count: 1
path: src/bundle/Debug/Twig/DebugTemplate.php

-
message: "#^Method Ibexa\\\\Bundle\\\\IO\\\\ApiLoader\\\\HandlerRegistry\\:\\:setHandlersMap\\(\\) has no return type specified\\.$#"
count: 1
Expand Down
26 changes: 9 additions & 17 deletions src/bundle/Debug/DependencyInjection/IbexaDebugExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,21 @@
*/
namespace Ibexa\Bundle\Debug\DependencyInjection;

use Ibexa\Bundle\Debug\Twig\DebugTemplate;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface;
use Symfony\Component\DependencyInjection\Loader;
use Symfony\Component\HttpKernel\DependencyInjection\Extension;

class IbexaDebugExtension extends Extension implements PrependExtensionInterface
/**
* @internal
* @final
*/
class IbexaDebugExtension extends Extension
{
public function load(array $configs, ContainerBuilder $container)
/**
* @throws \Exception
*/
public function load(array $configs, ContainerBuilder $container): void
{
$loader = new Loader\YamlFileLoader(
$container,
Expand All @@ -25,19 +30,6 @@ public function load(array $configs, ContainerBuilder $container)
// Base services and services overrides
$loader->load('services.yml');
}

/**
* Sets the twig base template class to this bundle's in order to collect template infos.
*/
public function prepend(ContainerBuilder $container)
{
if ($container->getParameter('kernel.debug')) {
$container->prependExtensionConfig(
'twig',
['base_template_class' => DebugTemplate::class]
);
}
}
}

class_alias(IbexaDebugExtension::class, 'eZ\Bundle\EzPublishDebugBundle\DependencyInjection\EzPublishDebugExtension');
93 changes: 0 additions & 93 deletions src/bundle/Debug/Twig/DebugTemplate.php

This file was deleted.

0 comments on commit 9a396e3

Please sign in to comment.