diff --git a/core/lib/Drupal/Core/Path/AliasStorage.php b/core/lib/Drupal/Core/Path/AliasStorage.php index 899c39e..9732cc8 100644 --- a/core/lib/Drupal/Core/Path/AliasStorage.php +++ b/core/lib/Drupal/Core/Path/AliasStorage.php @@ -8,6 +8,7 @@ namespace Drupal\Core\Path; use Drupal\Core\Cache\Cache; +use Drupal\Component\Utility\Unicode; use Drupal\Core\Database\Connection; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Language\LanguageInterface; @@ -59,7 +60,7 @@ public function save($source, $alias, $langcode = LanguageInterface::LANGCODE_NO $fields = array( 'source' => $source, - 'alias' => $alias, + 'alias' => Unicode::strtolower($alias), 'langcode' => $langcode, ); diff --git a/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php b/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php index d7bd416..ebad3ab 100644 --- a/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php +++ b/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php @@ -7,6 +7,8 @@ namespace Drupal\Core\PathProcessor; +use Drupal\Component\Utility\Unicode; +use Drupal\Core\Cache\CacheableMetadata; use Drupal\Core\Path\AliasManagerInterface; use Drupal\Core\Render\BubbleableMetadata; use Symfony\Component\HttpFoundation\Request; diff --git a/core/lib/Drupal/Core/Routing/RouteCompiler.php b/core/lib/Drupal/Core/Routing/RouteCompiler.php index 1d223ff..892422a 100644 --- a/core/lib/Drupal/Core/Routing/RouteCompiler.php +++ b/core/lib/Drupal/Core/Routing/RouteCompiler.php @@ -51,7 +51,7 @@ public static function compile(Route $route) { $num_parts, // These are the Symfony compiled parts. $symfony_compiled->getStaticPrefix(), - $symfony_compiled->getRegex(), + $symfony_compiled->getRegex() . 'i', $symfony_compiled->getTokens(), $symfony_compiled->getPathVariables(), $symfony_compiled->getHostRegex(), diff --git a/core/lib/Drupal/Core/Routing/RouteProvider.php b/core/lib/Drupal/Core/Routing/RouteProvider.php index 278b486..04e5284 100644 --- a/core/lib/Drupal/Core/Routing/RouteProvider.php +++ b/core/lib/Drupal/Core/Routing/RouteProvider.php @@ -8,6 +8,7 @@ namespace Drupal\Core\Routing; use Drupal\Core\Cache\CacheBackendInterface; +use Drupal\Component\Utility\Unicode; use Drupal\Core\Path\CurrentPathStack; use Drupal\Core\PathProcessor\InboundPathProcessorInterface; use Drupal\Core\State\StateInterface; @@ -300,7 +301,7 @@ public function getRoutesByPattern($pattern) { protected function getRoutesByPath($path) { // Filter out each empty value, though allow '0' and 0, which would be // filtered out by empty(). - $parts = array_values(array_filter(explode('/', $path), function($value) { + $parts = array_values(array_filter(explode('/', Unicode::strtolower($path)), function($value) { return $value !== NULL && $value !== ''; }));