Skip to content

Commit

Permalink
If range is escaped the replacement will fail. This is a fallback.
Browse files Browse the repository at this point in the history
  • Loading branch information
cradeck committed Jul 31, 2023
1 parent 5ffd0ec commit 6509a31
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Classes/Service/SolrServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,7 @@ protected function getFacetQuery(array $facetConfig, string $queryTerm, string $
// Hack: convert strings »RANGE XX TO YY« Solr style range queries »[XX TO YY]«
// (because PHP loses ] in array keys during URL parsing)
$queryTerm = preg_replace('#RANGE (.*) TO (.*)#', '[\1 TO \2]', $queryTerm);
$queryTerm = preg_replace('/RANGE\\\ (.*)\\\ TO\\\ (.*)/', '[\1 TO \2]', $queryTerm);
$queryString = sprintf($queryPattern, $queryTerm);
}
} else {
Expand Down

0 comments on commit 6509a31

Please sign in to comment.