8000 minor #51745 Minor CS fixes (nicolas-grekas) · symfony/symfony@0659364 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0659364

Browse files
minor #51745 Minor CS fixes (nicolas-grekas)
This PR was merged into the 6.4 branch. Discussion ---------- Minor CS fixes | Q | A | ------------- | --- | Branch? | 6.4 | Bug fix? | no | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Commits ------- 85345d2 Minor CS fixes
2 parents fbf6f56 + 85345d2 commit 0659364

File tree

52 files changed

+73
-84
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+73
-84
lines changed

src/Symfony/Bundle/FrameworkBundle/Command/ConfigDebugCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ private static function buildPathsCompletion(array $paths, string $prefix = ''):
259259
$completionPaths = [];
260260
foreach ($paths as $key => $values) {
261261
if (\is_array($values)) {
262-
$completionPaths = $completionPaths + self::buildPathsCompletion($values, $prefix.$key.'.');
262+
$completionPaths += self::buildPathsCompletion($values, $prefix.$key.'.');
263263
} else {
264264
$completionPaths[$prefix.$key] = null;
265265
}

src/Symfony/Bundle/FrameworkBundle/Command/TranslationDebugCommand.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,14 +212,14 @@ protected function execute(InputInterface $input, OutputInterface $output): int
212212
$states[] = self::MESSAGE_MISSING;
213213

214214
if (!$input->getOption('only-unused')) {
215-
$exitCode = $exitCode | self::EXIT_CODE_MISSING;
215+
$exitCode |= self::EXIT_CODE_MISSING;
216216
}
217217
}
218218
} elseif ($currentCatalogue->defines($messageId, $domain)) {
219219
$states[] = self::MESSAGE_UNUSED;
220220

221221
if (!$input->getOption('only-missing')) {
222-
$exitCode = $exitCode | self::EXIT_CODE_UNUSED;
222+
$exitCode |= self::EXIT_CODE_UNUSED;
223223
}
224224
}
225225

@@ -233,7 +233,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
233233
if ($fallbackCatalogue->defines($messageId, $domain) && $value === $fallbackCatalogue->get($messageId, $domain)) {
234234
$states[] = self::MESSAGE_EQUALS_FALLBACK;
235235

236-
$exitCode = $exitCode | self::EXIT_CODE_FALLBACK;
236+
$exitCode |= self::EXIT_CODE_FALLBACK;
237237

238238
break;
239239
}

src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1836,7 +1836,7 @@ private function addHttpClientSection(ArrayNodeDefinition $rootNode, callable $e
18361836
continue;
18371837
}
18381838
if (\is_array($scopedConfig['retry_failed'])) {
1839-
$scopedConfig['retry_failed'] = $scopedConfig['retry_failed'] + $config['default_options']['retry_failed'];
1839+
$scopedConfig['retry_failed'] += $config['default_options']['retry_failed'];
18401840
}
18411841
}
18421842

src/Symfony/Bundle/SecurityBundle/DependencyInjection/Security/AccessToken/OidcTokenHandlerFactory.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
namespace Symfony\Bundle\SecurityBundle\DependencyInjection\Security\AccessToken;
1313

1414
use Jose\Component\Core\Algorithm;
15-
use Jose\Component\Core\JWK;
1615
use Symfony\Component\Config\Definition\Builder\NodeBuilder;
1716
use Symfony\Component\DependencyInjection\ChildDefinition;
1817
use Symfony\Component\DependencyInjection\ContainerBuilder;

src/Symfony/Component/Console/Messenger/RunCommandMessage.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
class RunCommandMessage implements \Stringable
2020
{
2121
/**
22-
* @param bool $throwOnFailure If the command has a non-zero exit code, throw {@see RunCommandFailedException}
23-
* @param bool $catchExceptions @see Application::setCatchExceptions()
22+
* @param bool $throwOnFailure If the command has a non-zero exit code, throw {@see RunCommandFailedException}
23+
* @param bool $catchExceptions @see Application::setCatchExceptions()
2424
*/
2525
public function __construct(
2626
public readonly string $input,

src/Symfony/Component/Console/Tests/ApplicationTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ protected function tearDown(): void
7474
if (9 === $i) {
7575
continue;
7676
}
77-
pcntl_signal($i, SIG_DFL);
77+
pcntl_signal($i, \SIG_DFL);
7878
}
7979
}
8080
}
@@ -948,7 +948,7 @@ public function testRenderAnonymousException()
948948
$application = new Application();
949949
$application->setAutoExit(false);
950950
$application->register('foo')->setCode(function () {
951-
throw new class('') extends \InvalidArgumentException { };
951+
throw new class('') extends \InvalidArgumentException {};
952952
});
953953
$tester = new ApplicationTester($application);
954954

@@ -958,7 +958,7 @@ public function testRenderAnonymousException()
958958
$application = new Application();
959959
$application->setAutoExit(false);
960960
$application->register('foo')->setCode(function () {
961-
throw new \InvalidArgumentException(sprintf('Dummy type "%s" is invalid.', (new class() { })::class));
961+
throw new \InvalidArgumentException(sprintf('Dummy type "%s" is invalid.', (new class() {})::class));
962962
});
963963
$tester = new ApplicationTester($application);
964964

@@ -974,7 +974,7 @@ public function testRenderExceptionStackTraceContainsRootException()
974974
$application = new Application();
975975
$application->setAutoExit(false);
976976
$application->register('foo')->setCode(function () {
977-
throw new class('') extends \InvalidArgumentException { };
977+
throw new class('') extends \InvalidArgumentException {};
978978
});
979979
$tester = new ApplicationTester($application);
980980

@@ -984,7 +984,7 @@ public function testRenderExceptionStackTraceContainsRootException()
984984
$application = new Application();
985985
$application->setAutoExit(false);
986986
$application->register('foo')->setCode(function () {
987-
throw new \InvalidArgumentException(sprintf('Dummy type "%s" is invalid.', (new class() { })::class));
987+
throw new \InvalidArgumentException(sprintf('Dummy type "%s" is invalid.', (new class() {})::class));
988988
});
989989
$tester = new ApplicationTester($application);
990990

@@ -2081,7 +2081,7 @@ public function testSetSignalsToDispatchEvent()
20812081

20822082
// And now we test without the blank handler
20832083
$blankHandlerSignaled = false;
2084-
pcntl_signal(\SIGUSR1, SIG_DFL);
2084+
pcntl_signal(\SIGUSR1, \SIG_DFL);
20852085

20862086
$application = $this->createSignalableApplication($command, $dispatcher);
20872087
$application->setSignalsToDispatchEvent(\SIGUSR1);
@@ -2344,7 +2344,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
23442344

23452345
for ($i = 0; $i <= 10 && $this->shouldContinue; ++$i) {
23462346
$output->writeln('Still processing...');
2347-
posix_kill(posix_getpid(), SIGINT);
2347+
posix_kill(posix_getpid(), \SIGINT);
23482348
}
23492349

23502350
$output->writeln('Wrapping up, wait a sec...');

src/Symfony/Component/Console/Tests/ConsoleEventsTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ protected function tearDown(): void
3939
if (9 === $i) {
4040
continue;
4141
}
42-
pcntl_signal($i, SIG_DFL);
42+
pcntl_signal($i, \SIG_DFL);
4343
}
4444
}
4545
}

src/Symfony/Component/Console/Tests/SignalRegistry/SignalRegistryTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ protected function tearDown(): void
2727
if (9 === $i) {
2828
continue;
2929
}
30-
pcntl_signal($i, SIG_DFL);
30+
pcntl_signal($i, \SIG_DFL);
3131
}
3232
}
3333

src/Symfony/Component/Console/Tests/Style/SymfonyStyleTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525
use Symfony\Component\Console\Output\StreamOutput;
2626
use Symfony\Component\Console\Style\SymfonyStyle;
2727
use Symfony\Component\Console\Tester\CommandTester;
28-
use Symfony\Component\Console\Tests\Command\CommandTest;
2928

3029
class SymfonyStyleTest extends TestCase
3130
{

src/Symfony/Component/DependencyInjection/LazyProxy/Instantiator/InstantiatorInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ interface InstantiatorInterface
2525
/**
2626
* Instantiates a proxy object.
2727
*
28-
* @param string $id Identifier of the requested service
28+
* @param string $id Identifier of the requested service
2929
* @param callable(object=) $realInstantiator A callback that is capable of producing the real service instance
3030
*
3131
* @return object

src/Symfony/Component/DependencyInjection/Tests/Loader/IniFileLoaderTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
class IniFileLoaderTest extends TestCase
2121
{
22-
protected ContainerBuilder$container;
22+
protected ContainerBuilder $container;
2323
protected IniFileLoader $loader;
2424

2525
protected function setUp(): void

src/Symfony/Component/Form/Tests/Extension/Validator/ViolationMapper/ViolationMapperTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use PHPUnit\Framework\TestCase;
1515
use Symfony\Component\EventDispatcher\EventDispatcher;
16-
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
1716
use Symfony\Component\Form\CallbackTransformer;
1817
use Symfony\Component\Form\Exception\TransformationFailedException;
1918
use Symfony\Component\Form\Extension\Core\DataMapper\DataMapper;

src/Symfony/Component/Form/Tests/FormFactoryTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
use Symfony\Component\Form\Extension\Core\Type\TextType;
1717
use Symfony\Component\Form\FormFactory;
1818
use Symfony\Component\Form\FormRegistry;
19-
use Symfony\Component\Form\FormRegistryInterface;
2019
use Symfony\Component\Form\FormTypeGuesserChain;
2120
use Symfony\Component\Form\FormTypeGuesserInterface;
2221
use Symfony\Component\Form\Guess\Guess;

src/Symfony/Component/HttpClient/Retry/GenericRetryStrategy.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public function getDelay(AsyncContext $context, ?string $responseContent, ?Trans
103103

104104
if ($this->jitter > 0) {
105105
$randomness = (int) ($delay * $this->jitter);
106-
$delay = $delay + random_int(-$randomness, +$randomness);
106+
$delay += random_int(-$randomness, +$randomness);
107107
}
108108

109109
if ($delay > $this->maxDelayMs && 0 !== $this->maxDelayMs) {

src/Symfony/Component/HttpFoundation/Response.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@ public function sendHeaders(/* int $statusCode = null */): static
372372
$newValues = null === $previousValues ? $values : array_diff($values, $previousValues);
373373
}
374374

375-
foreach ($newValues as $value) {
375+
foreach ($newValues as $value) {
376376
header($name.': '.$value, $replace, $this->statusCode);
377377
}
378378

src/Symfony/Component/Lock/LockFactory.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Psr\Log\LoggerAwareInterface;
1515
use Psr\Log\LoggerAwareTrait;
16-
use Psr\Log\NullLogger;
1716

1817
/**
1918
* Factory provides method to create locks.

src/Symfony/Component/Mailer/Bridge/Brevo/Webhook/BrevoRequestParser.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313

1414
use Symfony\Component\HttpFoundation\ChainRequestMatcher;
1515
use Symfony\Component\HttpFoundation\Request;
16+
use Symfony\Component\HttpFoundation\RequestMatcher\IpsRequestMatcher;
1617
use Symfony\Component\HttpFoundation\RequestMatcher\IsJsonRequestMatcher;
1718
use Symfony\Component\HttpFoundation\RequestMatcher\MethodRequestMatcher;
18-
use Symfony\Component\HttpFoundation\RequestMatcher\IpsRequestMatcher;
1919
use Symfony\Component\HttpFoundation\RequestMatcherInterface;
2020
use Symfony\Component\Mailer\Bridge\Brevo\RemoteEvent\BrevoPayloadConverter;
2121
use Symfony\Component\RemoteEvent\Event\Mailer\AbstractMailerEvent;

src/Symfony/Component/Mailer/Bridge/Postmark/Webhook/PostmarkRequestParser.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818
use Symfony\Component\HttpFoundation\RequestMatcher\MethodRequestMatcher;
1919
use Symfony\Component\HttpFoundation\RequestMatcherInterface;
2020
use Symfony\Component\Mailer\Bridge\Postmark\RemoteEvent\PostmarkPayloadConverter;
21-
use Symfony\Component\Webhook\Client\AbstractRequestParser;
22-
use Symfony\Component\Webhook\Exception\RejectWebhookException;
2321
use Symfony\Component\RemoteEvent\Event\Mailer\AbstractMailerEvent;
2422
use Symfony\Component\RemoteEvent\Exception\ParseExce 10000 ption;
23+
use Symfony\Component\Webhook\Client\AbstractRequestParser;
24+
use Symfony\Component\Webhook\Exception\RejectWebhookException;
2525

2626
final class PostmarkRequestParser extends AbstractRequestParser
2727
{

src/Symfony/Component/Messenger/Bridge/AmazonSqs/Transport/AmazonSqsTransport.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class AmazonSqsTransport implements TransportInterface, SetupableTransportInterf
3434
private ?SenderInterface $sender;
3535

3636
/**
37-
* @param MessageCountAwareInterface&ReceiverInterface|null $receiver
37+
* @param (MessageCountAwareInterface&ReceiverInterface)|null $receiver
3838
*/
3939
public function __construct(Connection $connection, SerializerInterface $serializer = null, ReceiverInterface $receiver = null, SenderInterface $sender = null)
4040
{

src/Symfony/Component/Messenger/EventListener/StopWorkerOnSignalsListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class StopWorkerOnSignalsListener implements EventSubscriberInterface
3030
public function __construct(array $signals = null, LoggerInterface $logger = null)
3131
{
3232
if (null === $signals && \defined('SIGTERM')) {
33-
$signals = [SIGTERM, SIGINT];
33+
$signals = [\SIGTERM, \SIGINT];
3434
}
3535
$this->signals = $signals ?? [];
3636
$this->logger = $logger;

src/Symfony/Component/Messenger/EventListener/StopWorkerOnSigtermSignalListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,6 @@ class StopWorkerOnSigtermSignalListener extends StopWorkerOnSignalsListener
2525
{
2626
public function __construct(LoggerInterface $logger = null)
2727
{
28-
parent::__construct(\defined('SIGTERM') ? [SIGTERM] : [], $logger);
28+
parent::__construct(\defined('SIGTERM') ? [\SIGTERM] : [], $logger);
2929
}
3030
}

src/Symfony/Component/Notifier/Bridge/MicrosoftTeams/MicrosoftTeamsTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\MicrosoftTeams;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\ChatMessage;

src/Symfony/Component/Notifier/Bridge/Mobyt/MobytTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\Mobyt;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\MessageInterface;

src/Symfony/Component/Notifier/Bridge/PagerDuty/PagerDutyTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\PagerDuty;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\MessageInterface;

src/Symfony/Component/Notifier/Bridge/RocketChat/RocketChatTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\RocketChat;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\ChatMessage;

src/Symfony/Component/Notifier/Bridge/Slack/SlackTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
namespace Symfony\Component\Notifier\Bridge\Slack;
1313

1414
use Symfony\Component\Notifier\Exception\InvalidArgumentException;
15-
use Symfony\Component\Notifier\Exception\LogicException;
1615
use Symfony\Component\Notifier\Exception\TransportException;
1716
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1817
use Symfony\Component\Notifier\Message\ChatMessage;

src/Symfony/Component/Notifier/Bridge/Smsmode/Tests/SmsmodeTransportTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
use Symfony\Component\Notifier\Bridge\Smsmode\SmsmodeTransport;
1717
use Symfony\Component\Notifier\Exception\InvalidArgumentException;
1818
use Symfony\Component\Notifier\Message\ChatMessage;
19-
use Symfony\Component\Notifier\Message\MessageInterface;
2019
use Symfony\Component\Notifier\Message\SmsMessage;
2120
use Symfony\Component\Notifier\Test\TransportTestCase;
2221
use Symfony\Component\Notifier\Tests\Transport\DummyMessage;

src/Symfony/Component/Notifier/Bridge/Telegram/TelegramTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\Telegram;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\ChatMessage;

src/Symfony/Component/Notifier/Bridge/Twilio/TwilioTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
namespace Symfony\Component\Notifier\Bridge\Twilio;
1313

1414
use Symfony\Component\Notifier\Exception\InvalidArgumentException;
15-
use Symfony\Component\Notifier\Exception\LogicException;
1615
use Symfony\Component\Notifier\Exception\TransportException;
1716
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1817
use Symfony\Component\Notifier\Message\MessageInterface;

src/Symfony/Component/Notifier/Bridge/Zendesk/ZendeskTransport.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
namespace Symfony\Component\Notifier\Bridge\Zendesk;
1313

14-
use Symfony\Component\Notifier\Exception\LogicException;
1514
use Symfony\Component\Notifier\Exception\TransportException;
1615
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
1716
use Symfony\Component\Notifier\Message\ChatMessage;

src/Symfony/Component/Process/Messenger/RunProcessMessage.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,6 @@ public function __construct(
2727

2828
public function __toString(): string
2929
{
30-
return \implode(' ', $this->command);
30+
return implode(' ', $this->command);
3131
}
3232
}

src/Symfony/Component/PropertyAccess/PropertyAccessorInterface.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ interface PropertyAccessorInterface
3939
*
4040
* If neither is found, an exception is thrown.
4141
*
42+
* @return void
43+
*
4244
* @throws Exception\InvalidArgumentException If the property path is invalid
4345
* @throws Exception\AccessException If a property/index does not exist or is not public
4446
* @throws Exception\UnexpectedTypeException If a value within the path is neither object nor array
45-
*
46-
* @return void
4747
*/
4848
public function setValue(object|array &$objectOrArray, string|PropertyPathInterface $propertyPath, mixed $value);
4949

src/Symfony/Component/Scheduler/Command/DebugCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
9696
}
9797
$io->table(
9898
['Message', 'Trigger', 'Next Run'],
99-
array_filter(array_map(self::renderRecurringMessage(...), $messages, array_fill(0, count($messages), $date), array_fill(0, count($messages), $input->getOption('all')))),
99+
array_filter(array_map(self::renderRecurringMessage(...), $messages, array_fill(0, \count($messages), $date), array_fill(0, \count($messages), $input->getOption('all')))),
100100
);
101101
}
102102

src/Symfony/Component/Scheduler/Generator/MessageGenerator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ private function heap(\DateTimeImmutable $time, \DateTime B41A Immutable $startTime):
9090
$heap = new TriggerHeap($time);
9191

9292
foreach ($this->schedule()->getRecurringMessages() as $index => $recurringMessage) {
93-
$trigger = $recurringMessage->getTrigger();
93+
$trigger = $recurringMessage->getTrigger();
9494

9595
if ($trigger instanceof StatefulTriggerInterface) {
9696
$trigger->continue($startTime);

src/Symfony/Component/Scheduler/RecurringMessage.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ private function __construct(
4040
* @see https://en.wikipedia.org/wiki/ISO_8601#Durations
4141
* @see https://php.net/datetime.formats.relative
4242
*/
43-
public static function every(string|int|\DateInterval $frequency, object $message, string|\DateTimeImmutable|null $from = null, string|\DateTimeImmutable $until = new \DateTimeImmutable('3000-01-01')): self
43+
public static function every(string|int|\DateInterval $frequency, object $message, string|\DateTimeImmutable $from = null, string|\DateTimeImmutable $until = new \DateTimeImmutable('3000-01-01')): self
4444
{
4545
return new self(new PeriodicalTrigger($frequency, $from, $until), $message);
4646
}

src/Symfony/Component/Scheduler/Tests/Messenger/SchedulerTransportTest.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,9 @@ public function testAddsStampToInnerRedispatchMessageEnvelope()
5353
{
5454
$generator = $this->createMock(MessageGeneratorInterface::class);
5555
$generator->method('getMessages')->willReturnCallback(function (): \Generator {
56-
yield new MessageContext('default', 'id', $this->createMock(TriggerInterface::class), new \DateTimeImmutable()) =>
57-
new RedispatchMessage(new \stdClass(), ['transport']);
56+
yield new MessageContext('default', 'id', $this->createMock(TriggerInterface::class), new \DateTimeImmutable()) => new RedispatchMessage(new \stdClass(), ['transport']);
5857
});
59-
$envelopes = \iterator_to_array((new SchedulerTransport($generator))->get());
58+
$envelopes = iterator_to_array((new SchedulerTransport($generator))->get());
6059

6160
$stamp = $envelopes[0]->getMessage()->envelope->last(ScheduledStamp::class);
6261

0 commit comments

Comments
 (0)
0