Skip to content

Commit

Permalink
FIX Accept spaces around the | criteria
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Jan 7, 2017
1 parent 6585431 commit 37d158f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion htdocs/core/lib/functions.lib.php
Expand Up @@ -5737,7 +5737,9 @@ function natural_search($fields, $value, $mode=0, $nofirstand=0)
else // $mode=0
{
$textcrit = '';
$tmpcrits = explode('|',$crit);
$tmpcrit = preg_replace('/\s+|/','|',$tmpcrit);
$tmpcrit = preg_replace('/|\s+/','|',$tmpcrit);
$tmpcrits = explode('|',$tmpcrit);
$i3 = 0;
foreach($tmpcrits as $tmpcrit)
{
Expand Down

0 comments on commit 37d158f

Please sign in to comment.