Skip to content

Commit

Permalink
[BUGFIX] Infinite loop in SolrRoutingMiddleware #3873
Browse files Browse the repository at this point in the history
Fixes infinite loop and therefore server crashing if route doesn't exist or URl is in the scheme like domain/id=123456

Fixes: #3873
  • Loading branch information
superyaro authored and dkd-kaehm committed Nov 15, 2023
1 parent ce3a3ea commit 7c9dae1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Classes/Middleware/SolrRoutingMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@ protected function retrievePageInformation(UriInterface $uri, Site $site): array

if ($scan) {
$elements = explode('/', $path);
if (empty($elements)) {
if (empty($elements) || $path === '') {
$scan = false;
} else {
array_pop($elements);
Expand Down

0 comments on commit 7c9dae1

Please sign in to comment.