From d4b51f041f801e2eb71c12132ceee5aaaccb73da Mon Sep 17 00:00:00 2001 From: Jonathan Sacksick <jonathan.sacksick@gmail.com> Date: Thu, 7 Dec 2023 14:00:25 +0200 Subject: [PATCH] Issue #3406432 followup by jsacksick: Stop ignoring the toRenderArray() deprecations(). --- .../Plugin/views/area/CouponRedemption.php | 4 +--- phpstan-baseline.neon | 23 ------------------- 2 files changed, 1 insertion(+), 26 deletions(-) diff --git a/modules/promotion/src/Plugin/views/area/CouponRedemption.php b/modules/promotion/src/Plugin/views/area/CouponRedemption.php index 5ea05cfab..f1c5999f1 100644 --- a/modules/promotion/src/Plugin/views/area/CouponRedemption.php +++ b/modules/promotion/src/Plugin/views/area/CouponRedemption.php @@ -195,9 +195,7 @@ class CouponRedemption extends AreaPluginBase { $order_total['#suffix'] = '</div>'; $response = new AjaxResponse(); - if (isset($order_total)) { - $response->addCommand(new ReplaceCommand('[data-drupal-selector="order-total-summary"]', $order_total)); - } + $response->addCommand(new ReplaceCommand('[data-drupal-selector="order-total-summary"]', $order_total)); $response->addCommand(new InsertCommand('[data-drupal-selector="' . $inline_form['#attributes']['data-drupal-selector'] . '"]', $inline_form)); $response->addCommand(new PrependCommand('[data-drupal-selector="' . $inline_form['#attributes']['data-drupal-selector'] . '"]', ['#type' => 'status_messages'])); diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 5060c5fc6..90c947364 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -210,15 +210,6 @@ parameters: count: 1 path: modules/product/src/Plugin/Validation/Constraint/ProductVariationSkuConstraintValidator.php - - - message: """ - #^Call to deprecated method toRenderArray\\(\\) of class Drupal\\\\Core\\\\Url\\: - in drupal\\:10\\.1\\.0 and is removed from drupal\\:11\\.0\\.0\\. There is no - replacement\\.$# - """ - count: 1 - path: modules/product/src/ProductListBuilder.php - - message: "#^\\\\Drupal calls should be avoided in classes, use dependency injection instead$#" count: 1 @@ -244,11 +235,6 @@ parameters: count: 1 path: modules/promotion/src/Plugin/views/area/CouponRedemption.php - - - message: "#^Variable \\$order_total in isset\\(\\) always exists and is not nullable\\.$#" - count: 1 - path: modules/promotion/src/Plugin/views/area/CouponRedemption.php - - message: """ #^Call to deprecated function system_time_zones\\(\\)\\: @@ -270,15 +256,6 @@ parameters: count: 1 path: modules/store/src/Form/StoreTypeForm.php - - - message: """ - #^Call to deprecated method toRenderArray\\(\\) of class Drupal\\\\Core\\\\Url\\: - in drupal\\:10\\.1\\.0 and is removed from drupal\\:11\\.0\\.0\\. There is no - replacement\\.$# - """ - count: 1 - path: modules/store/src/StoreListBuilder.php - - message: "#^Method Drupal\\\\commerce_tax\\\\Form\\\\TaxTypeForm\\:\\:save\\(\\) should return int but return statement is missing\\.$#" count: 1 -- GitLab