From 2a461dcd71eb22c8a7078499ac58d425d1ef75ca Mon Sep 17 00:00:00 2001 From: xjm <xjm@65776.no-reply.drupal.org> Date: Fri, 16 Dec 2022 13:21:42 -0600 Subject: [PATCH] Issue #3325184 by Spokje, andypost, xjm, smustgrave: $this->configFactory is not set properly in the constructor of \Drupal\system\Form\CronForm --- core/modules/system/src/Form/CronForm.php | 1 + core/phpstan-baseline.neon | 5 ----- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/core/modules/system/src/Form/CronForm.php b/core/modules/system/src/Form/CronForm.php index 177d973e6716..4e7827d11dd0 100644 --- a/core/modules/system/src/Form/CronForm.php +++ b/core/modules/system/src/Form/CronForm.php @@ -65,6 +65,7 @@ class CronForm extends FormBase { * The module handler service. */ public function __construct(ConfigFactoryInterface $config_factory, StateInterface $state, CronInterface $cron, DateFormatterInterface $date_formatter, ModuleHandlerInterface $module_handler) { + $this->configFactory = $config_factory; $this->state = $state; $this->cron = $cron; $this->dateFormatter = $date_formatter; diff --git a/core/phpstan-baseline.neon b/core/phpstan-baseline.neon index c6272077f13b..cf84abce27b0 100644 --- a/core/phpstan-baseline.neon +++ b/core/phpstan-baseline.neon @@ -2065,11 +2065,6 @@ parameters: count: 1 path: modules/system/src/DateFormatListBuilder.php - - - message: "#^Constructor of class Drupal\\\\system\\\\Form\\\\CronForm has an unused parameter \\$config_factory\\.$#" - count: 1 - path: modules/system/src/Form/CronForm.php - - message: "#^Call to deprecated constant REQUEST_TIME\\: Deprecated in drupal\\:8\\.3\\.0 and is removed from drupal\\:10\\.0\\.0\\. Use \\\\Drupal\\:\\:time\\(\\)\\-\\>getRequestTime\\(\\); $#" count: 1 -- GitLab