Skip to content

Commit

Permalink
Set as public RequestTask. Fix RegistryCompilerPass using service nam…
Browse files Browse the repository at this point in the history
…e instead of class FQCN.
  • Loading branch information
njoubert-cleverage committed Nov 27, 2024
1 parent ecc4715 commit 7e98456
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
1 change: 1 addition & 0 deletions config/services/task.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ services:
- { name: monolog.logger, channel: cleverage_process_task }
CleverAge\SoapProcessBundle\Task\RequestTask:
alias: cleverage_soap_process.task.request
public: true
3 changes: 1 addition & 2 deletions src/CleverAgeSoapProcessBundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
namespace CleverAge\SoapProcessBundle;

use CleverAge\ProcessBundle\DependencyInjection\Compiler\RegistryCompilerPass;
use CleverAge\SoapProcessBundle\Registry\ClientRegistry;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;

Expand All @@ -27,7 +26,7 @@ public function build(ContainerBuilder $container): void
{
$container->addCompilerPass(
new RegistryCompilerPass(
ClientRegistry::class,
'cleverage_soap_process.registry.client',
'cleverage.soap.client',
'addClient'
)
Expand Down
8 changes: 6 additions & 2 deletions src/Client/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,12 @@ class Client implements ClientInterface
/**
* Client constructor.
*/
public function __construct(private readonly LoggerInterface $logger, private readonly string $code, private ?string $wsdl, private array $options)
{
public function __construct(
private readonly LoggerInterface $logger,
private readonly string $code,
private ?string $wsdl,
private array $options = [],
) {
}

public function getLogger(): LoggerInterface
Expand Down

0 comments on commit 7e98456

Please sign in to comment.