Code Coverage
 
Lines
Branches
Paths
Functions and Methods
Classes and Traits
Total
0.00% covered (danger)
0.00%
0 / 3
n/a
0 / 0
n/a
0 / 0
0.00% covered (danger)
0.00%
0 / 2
CRAP
0.00% covered (danger)
0.00%
0 / 1
SendNotificationCommandHandler
0.00% covered (danger)
0.00%
0 / 2
n/a
0 / 0
n/a
0 / 0
0.00% covered (danger)
0.00%
0 / 2
6
0.00% covered (danger)
0.00%
0 / 1
 __construct
0.00% covered (danger)
0.00%
0 / 1
n/a
0 / 0
n/a
0 / 0
0.00% covered (danger)
0.00%
0 / 1
2
 __invoke
0.00% covered (danger)
0.00%
0 / 1
n/a
0 / 0
n/a
0 / 0
0.00% covered (danger)
0.00%
0 / 1
2
1<?php
2
3namespace App\MessageHandler;
4
5use App\Application\Handler\SendNotificationCommandHandlerInterface;
6use App\Message\SendNotificationCommand;
7use Symfony\Component\Messenger\Attribute\AsMessageHandler;
8
9/**
10 * @author Wilhelm Zwertvaegher
11 */
12#[AsMessageHandler]
13readonly class SendNotificationCommandHandler implements CommandHandler
14{
15    public function __construct(private SendNotificationCommandHandlerInterface $notificationCommandHandler)
16    {
17    }
18
19    public function __invoke(SendNotificationCommand $command): void
20    {
21        ($this->notificationCommandHandler)($command);
22    }
23}