Verified Commit 0be587c4 authored by Alex Pott's avatar Alex Pott
Browse files

Issue #3269149 by longwave, catch, alexpott: Remove deprecated settings

parent 43a7efe7
Loading
Loading
Loading
Loading
+0 −9
Original line number Diff line number Diff line
@@ -21,15 +21,6 @@ class RequestSanitizer {
   */
  const SANITIZE_INPUT_SAFE_KEYS = 'sanitize_input_safe_keys';

  /**
   * Previous name of SANITIZE_INPUT_SAFE_KEYS.
   *
   * @deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use
   *   SANITIZE_INPUT_SAFE_KEYS instead.
   * @see https://www.drupal.org/node/3163148
   */
  const SANITIZE_WHITELIST = 'sanitize_input_whitelist';

  /**
   * The name of the setting that determines if sanitized keys are logged.
   */
+1 −18
Original line number Diff line number Diff line
@@ -37,24 +37,7 @@ final class Settings {
   *
   * @see self::handleDeprecations()
   */
  private static $deprecatedSettings = [
    'sanitize_input_whitelist' => [
      'replacement' => 'sanitize_input_safe_keys',
      'message' => 'The "sanitize_input_whitelist" setting is deprecated in drupal:9.1.0 and will be removed in drupal:10.0.0. Use Drupal\Core\Security\RequestSanitizer::SANITIZE_INPUT_SAFE_KEYS instead. See https://www.drupal.org/node/3163148.',
    ],
    'twig_sandbox_whitelisted_classes' => [
      'replacement' => 'twig_sandbox_allowed_classes',
      'message' => 'The "twig_sandbox_whitelisted_classes" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_classes" instead. See https://www.drupal.org/node/3162897.',
    ],
    'twig_sandbox_whitelisted_methods' => [
      'replacement' => 'twig_sandbox_allowed_methods',
      'message' => 'The "twig_sandbox_whitelisted_methods" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_methods" instead. See https://www.drupal.org/node/3162897.',
    ],
    'twig_sandbox_whitelisted_prefixes' => [
      'replacement' => 'twig_sandbox_allowed_prefixes',
      'message' => 'The "twig_sandbox_whitelisted_prefixes" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_prefixes" instead. See https://www.drupal.org/node/3162897.',
    ],
  ];
  private static $deprecatedSettings = [];

  /**
   * Constructor.
+1 −18
Original line number Diff line number Diff line
@@ -303,24 +303,7 @@ public function testRealDeprecatedSettings(string $legacy_setting, string $expec
   * Provides data for testRealDeprecatedSettings().
   */
  public function providerTestRealDeprecatedSettings(): array {
    return [
      [
        'sanitize_input_whitelist',
        'The "sanitize_input_whitelist" setting is deprecated in drupal:9.1.0 and will be removed in drupal:10.0.0. Use Drupal\Core\Security\RequestSanitizer::SANITIZE_INPUT_SAFE_KEYS instead. See https://www.drupal.org/node/3163148.',
      ],
      [
        'twig_sandbox_whitelisted_classes',
        'The "twig_sandbox_whitelisted_classes" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_classes" instead. See https://www.drupal.org/node/3162897.',
      ],
      [
        'twig_sandbox_whitelisted_methods',
        'The "twig_sandbox_whitelisted_methods" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_methods" instead. See https://www.drupal.org/node/3162897.',
      ],
      [
        'twig_sandbox_whitelisted_prefixes',
        'The "twig_sandbox_whitelisted_prefixes" setting is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. Use "twig_sandbox_allowed_prefixes" instead. See https://www.drupal.org/node/3162897.',
      ],
    ];
    return [];
  }

}