diff --git a/core/lib/Drupal/Core/Routing/RouteProvider.php b/core/lib/Drupal/Core/Routing/RouteProvider.php index 534670f8de8bfb6fea1d611c92e265af5d6ae1f2..1bd1cc2380670274be9638483bdc9e50678e789b 100644 --- a/core/lib/Drupal/Core/Routing/RouteProvider.php +++ b/core/lib/Drupal/Core/Routing/RouteProvider.php @@ -349,7 +349,7 @@ protected function getRoutesByPath($path) { // have a case-insensitive match from the incoming path to the lower case // pattern outlines from \Drupal\Core\Routing\RouteCompiler::compile(). // @see \Drupal\Core\Routing\CompiledRoute::__construct() - $parts = preg_split('@/+@', mb_strtolower($path), NULL, PREG_SPLIT_NO_EMPTY); + $parts = preg_split('@/+@', mb_strtolower($path), -1, PREG_SPLIT_NO_EMPTY); $collection = new RouteCollection(); diff --git a/core/modules/search/search.module b/core/modules/search/search.module index 4d6a1234e6a4c3d310bfef5b1aa25b89bf9ebd28..747efa796e8ec3c6d5f0cd282c01d2dd911ff709 100644 --- a/core/modules/search/search.module +++ b/core/modules/search/search.module @@ -506,7 +506,7 @@ function _search_find_match_with_simplify($key, $text, $boundary, $langcode = NU } // Split $text into words, keeping track of where the word boundaries are. - $words = preg_split('/' . $boundary . '+/u', $text, NULL, PREG_SPLIT_OFFSET_CAPTURE); + $words = preg_split('/' . $boundary . '+/u', $text, -1, PREG_SPLIT_OFFSET_CAPTURE); // Add an entry pointing to the end of the string, for the loop below. $words[] = ['', strlen($text)];