Skip to content

Commit c1ad9bd

Browse files
committed
Merge branch '5.4' into 6.0
* 5.4: [Security][WIP] Add authenticators info to the profiler [Translation] Use symfony default locale when pulling translations from providers added missing translations for Bosnian (bs) Add the missing greek translations for security core and validator component [HttpKernel] Fix return types in `EventDataCollector` Do not call substr_count() if ip is null to avoid deprecation warning in PHP 8.1 [Security][Validator] Add missing translations for Slovenian (sl) [Messenger] Add worker metadata inside logs [Messenger] Log when worker should stop and when `SIGTERM` is received cs fix [Security][Validator] Add missing translations for Finnish (fi) [VarDumper] returns a 500 when dd() is executed chore(VarDumper): declare that dd() never returns [MonologBridge] Deprecate the Swiftmailer handler [Cache] Commit items implicitly only when deferred keys are requested [MonologBridge] Deprecates ResetLoggersWorkerSubscriber Fix "can not" spelling [HttpClient] fix missing kernel.reset tag on TraceableHttpClient services [Form] Fix ChoiceType Extension to effectively set and use the translator Added new CssColor constraint
2 parents 4fc3d73 + c8f18ee commit c1ad9bd

File tree

6 files changed

+13
-10
lines changed

6 files changed

+13
-10
lines changed

Command/AssetsInstallCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ private function absoluteSymlinkWithFallback(string $originDir, string $targetDi
231231
/**
232232
* Creates symbolic link.
233233
*
234-
* @throws IOException if link can not be created
234+
* @throws IOException if link cannot be created
235235
*/
236236
private function symlink(string $originDir, string $targetDir, bool $relative = false)
237237
{

Command/ContainerDebugCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,9 +206,9 @@ protected function validateInput(InputInterface $input)
206206

207207
$name = $input->getArgument('name');
208208
if ((null !== $name) && ($optionsCount > 0)) {
209-
throw new InvalidArgumentException('The options tags, tag, parameters & parameter can not be combined with the service name argument.');
209+
throw new InvalidArgumentException('The options tags, tag, parameters & parameter cannot be combined with the service name argument.');
210210
} elseif ((null === $name) && $optionsCount > 1) {
211-
throw new InvalidArgumentException('The options tags, tag, parameters & parameter can not be combined together.');
211+
throw new InvalidArgumentException('The options tags, tag, parameters & parameter cannot be combined together.');
212212
}
213213
}
214214

Controller/AbstractController.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ protected function addFlash(string $type, mixed $message): void
175175
try {
176176
$this->container->get('request_stack')->getSession()->getFlashBag()->add($type, $message);
177177
} catch (SessionNotFoundException $e) {
178-
throw new \LogicException('You can not use the addFlash method if sessions are disabled. Enable them in "config/packages/framework.yaml".', 0, $e);
178+
throw new \LogicException('You cannot use the addFlash method if sessions are disabled. Enable them in "config/packages/framework.yaml".', 0, $e);
179179
}
180180
}
181181

@@ -216,7 +216,7 @@ protected function denyAccessUnlessGranted(mixed $attribute, mixed $subject = nu
216216
protected function renderView(string $view, array $parameters = []): string
217217
{
218218
if (!$this->container->has('twig')) {
219-
throw new \LogicException('You can not use the "renderView" method if the Twig Bundle is not available. Try running "composer require symfony/twig-bundle".');
219+
throw new \LogicException('You cannot use the "renderView" method if the Twig Bundle is not available. Try running "composer require symfony/twig-bundle".');
220220
}
221221

222222
return $this->container->get('twig')->render($view, $parameters);
@@ -274,7 +274,7 @@ protected function renderForm(string $view, array $parameters = [], Response $re
274274
protected function stream(string $view, array $parameters = [], StreamedResponse $response = null): StreamedResponse
275275
{
276276
if (!$this->container->has('twig')) {
277-
throw new \LogicException('You can not use the "stream" method if the Twig Bundle is not available. Try running "composer require symfony/twig-bundle".');
277+
throw new \LogicException('You cannot use the "stream" method if the Twig Bundle is not available. Try running "composer require symfony/twig-bundle".');
278278
}
279279

280280
$twig = $this->container->get('twig');
@@ -316,7 +316,7 @@ protected function createNotFoundException(string $message = 'Not Found', \Throw
316316
protected function createAccessDeniedException(string $message = 'Access Denied.', \Throwable $previous = null): AccessDeniedException
317317
{
318318
if (!class_exists(AccessDeniedException::class)) {
319-
throw new \LogicException('You can not use the "createAccessDeniedException" method if the Security component is not available. Try running "composer require symfony/security-bundle".');
319+
throw new \LogicException('You cannot use the "createAccessDeniedException" method if the Security component is not available. Try running "composer require symfony/security-bundle".');
320320
}
321321

322322
return new AccessDeniedException($message, $previous);
@@ -381,7 +381,7 @@ protected function isCsrfTokenValid(string $id, ?string $token): bool
381381
protected function addLink(Request $request, LinkInterface $link): void
382382
{
383383
if (!class_exists(AddLinkHeaderListener::class)) {
384-
throw new \LogicException('You can not use the "addLink" method if the WebLink component is not available. Try running "composer require symfony/web-link".');
384+
throw new \LogicException('You cannot use the "addLink" method if the WebLink component is not available. Try running "composer require symfony/web-link".');
385385
}
386386

387387
if (null === $linkProvider = $request->attributes->get('_links')) {

Controller/TemplateController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function __construct(Environment $twig = null)
4242
public function templateAction(string $template, int $maxAge = null, int $sharedAge = null, bool $private = null, array $context = []): Response
4343
{
4444
if (null === $this->twig) {
45-
throw new \LogicException('You can not use the TemplateController if the Twig Bundle is not available.');
45+
throw new \LogicException('You cannot use the TemplateController if the Twig Bundle is not available.');
4646
}
4747

4848
$response = new Response($this->twig->render($template, $context));

Resources/config/messenger.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,9 @@
193193
->tag('monolog.logger', ['channel' => 'messenger'])
194194

195195
->set('messenger.listener.stop_worker_on_sigterm_signal_listener', StopWorkerOnSigtermSignalListener::class)
196+
->args([
197+
service('logger')->ignoreOnInvalid(),
198+
])
196199
->tag('kernel.event_subscriber')
197200

198201
->set('messenger.listener.stop_worker_on_stop_exception_listener', StopWorkerOnCustomStopExceptionListener::class)

Tests/Controller/TemplateControllerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public function testTwig()
3535
public function testNoTwig()
3636
{
3737
$this->expectException(\LogicException::class);
38-
$this->expectExceptionMessage('You can not use the TemplateController if the Twig Bundle is not available.');
38+
$this->expectExceptionMessage('You cannot use the TemplateController if the Twig Bundle is not available.');
3939
$controller = new TemplateController();
4040

4141
$controller->templateAction('mytemplate')->getContent();

0 commit comments

Comments
 (0)