Commit 9aabbee8 authored by catch's avatar catch
Browse files

Issue #3254866 by benjifisher, alexpott: Update the deprecation notices...

Issue #3254866 by benjifisher, alexpott: Update the deprecation notices related to "Manage Permissions" pages
parent e3a49e2a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ services:
     - { name: event_subscriber }
  field_ui.route_enhancer:
    alias: route_enhancer.entity_bundle
    deprecated: The "%alias_id%" service is deprecated in drupal:9.3.0 and is removed from drupal:10.0.0. Use the "route_enhancer.entity_bundle" service instead. See https://www.drupal.org/node/3245017
    deprecated: The "%alias_id%" service is deprecated in drupal:9.4.0 and is removed from drupal:10.0.0. Use the "route_enhancer.entity_bundle" service instead. See https://www.drupal.org/node/3245017
    class: Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer
    arguments: ['@entity_type.manager']
    tags:
+2 −2
Original line number Diff line number Diff line
@@ -2,14 +2,14 @@

namespace Drupal\field_ui\Routing;

@trigger_error('The ' . __NAMESPACE__ . '\EntityBundleRouteEnhancer is deprecated in drupal:9.3.0 and is removed from drupal:10.0.0. Instead, use \Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer. See https://www.drupal.org/node/3245017', E_USER_DEPRECATED);
@trigger_error('The ' . __NAMESPACE__ . '\EntityBundleRouteEnhancer is deprecated in drupal:9.4.0 and is removed from drupal:10.0.0. Instead, use \Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer. See https://www.drupal.org/node/3245017', E_USER_DEPRECATED);

use Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer;

/**
 * Enhances Field UI routes by adding proper information about the bundle name.
 *
 * @deprecated in drupal:9.3.0 and is removed from drupal:10.0.0.
 * @deprecated in drupal:9.4.0 and is removed from drupal:10.0.0.
 * Use \Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer.
 *
 * @see https://www.drupal.org/node/3245017
+1 −1
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@ class FieldUiRouteEnhancerTest extends KernelTestBase {
   * Tests deprecation of the "field_ui.route_enhancer" service.
   */
  public function testFieldUiRouteEnhancerDeprecation() {
    $this->expectDeprecation('The "field_ui.route_enhancer" service is deprecated in drupal:9.3.0 and is removed from drupal:10.0.0. Use the "route_enhancer.entity_bundle" service instead. See https://www.drupal.org/node/3245017');
    $this->expectDeprecation('The "field_ui.route_enhancer" service is deprecated in drupal:9.4.0 and is removed from drupal:10.0.0. Use the "route_enhancer.entity_bundle" service instead. See https://www.drupal.org/node/3245017');
    $legacy_service = \Drupal::service('field_ui.route_enhancer');
    $new_service = \Drupal::service('route_enhancer.entity_bundle');
    $this->assertSame($new_service, $legacy_service);
+1 −1
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@ class FieldUiRouteEnhancerTest extends UnitTestCase {
   * class.
   */
  public function testDeprecation() {
    $this->expectDeprecation('The Drupal\field_ui\Routing\EntityBundleRouteEnhancer is deprecated in drupal:9.3.0 and is removed from drupal:10.0.0. Instead, use \Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer. See https://www.drupal.org/node/3245017');
    $this->expectDeprecation('The Drupal\field_ui\Routing\EntityBundleRouteEnhancer is deprecated in drupal:9.4.0 and is removed from drupal:10.0.0. Instead, use \Drupal\Core\Entity\Enhancer\EntityBundleRouteEnhancer. See https://www.drupal.org/node/3245017');
    $entity_type_manager = $this->prophesize(EntityTypeManagerInterface::class)->reveal();
    $route_enhancer = new FieldUiRouteEnhancer($entity_type_manager);
  }