From eb751c875def5955b4810c4b5b52ebe08ca157be Mon Sep 17 00:00:00 2001 From: Kristen Pol Date: Wed, 28 Feb 2024 21:57:27 -0800 Subject: [PATCH] Added home page path prefixes. --- src/Utility.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Utility.php b/src/Utility.php index b4895ed6..b4738127 100644 --- a/src/Utility.php +++ b/src/Utility.php @@ -180,6 +180,15 @@ public static function getSpecialPages() { '/_quant403', ]; + // Add translations of home page. + if (self::usesLanguagePathPrefixes()) { + if ($prefixes = \Drupal::config('language.negotiation')->get('url.prefixes')) { + foreach ($prefixes as $prefix) { + $pages[] = "/{$prefix}"; + } + } + } + $validator = \Drupal::service('path.validator'); foreach ($pages as $index => $page) { // Remove any pages that don't exist.