mirror of
				https://gitlab.com/Chill-Projet/chill-bundles.git
				synced 2025-10-31 01:08:26 +00:00 
			
		
		
		
	fix usage of parenthesis in search
This commit is contained in:
		| @@ -85,3 +85,4 @@ Master branch | ||||
| ============= | ||||
|  | ||||
| - fix errors in pagination | ||||
| - fix search: usage of parenthesis | ||||
|   | ||||
| @@ -76,7 +76,14 @@ abstract class AbstractSearch implements SearchInterface | ||||
|         foreach ($supportedTerms as $term) { | ||||
|             if (array_key_exists($term, $terms) && $term !== '_default') { | ||||
|                 $recomposed .= ' '.$term.':'; | ||||
|                 $containsSpace = \strpos($terms[$term], " ") !== false; | ||||
|                 if ($containsSpace) { | ||||
|                     $recomposed .= "("; | ||||
|                 } | ||||
|                 $recomposed .= (mb_stristr(' ', $terms[$term]) === FALSE) ?  $terms[$term] : '('.$terms[$term].')'; | ||||
|                 if ($containsSpace) { | ||||
|                     $recomposed .= ")"; | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|          | ||||
|   | ||||
		Reference in New Issue
	
	Block a user