fixed typos

This commit is contained in:
Viktor Pedersen 2021-08-05 14:38:42 +02:00
parent 60fe925565
commit 25cbafb475

@ -130,7 +130,7 @@ class SearchPage extends Page {
/*
Takes two arrays ($type, $terms)
Returns an array ($out) of products (from $type) based on matches with search query terms ($terms)
Returns an array ($out) of products ($type) based on matches with search query terms ($terms)
*/
@ -176,13 +176,11 @@ class SearchPage extends Page {
// adds to mustIncludeArray
$mustIncludeArray[] = array(substr($term[$i], 1))
//echo "test print " substr($term[$i], 1);
}
elseif($term[$i][0] == "!" || $term[$i][0] == "-") {
} elseif($term[$i][0] == "!" || $term[$i][0] == "-") {
// adds to mustExcludeArray
$mustExcludeArray[] = array(substr($term[$i], 1))
//echo "test print " substr($term[$i], 1);
}
else {
} else {
// adds to canIncludeArray
$canIncludeArray[] = array($term)
}
@ -197,14 +195,12 @@ class SearchPage extends Page {
foreach($mustIncludeArray as $mustIncludeArgument) {
if($item->matches($mustIncludeArgument)) {
$result = True;
}
else {
} else {
$result = False;
break;
}
}
}
else {
} else {
$result = True;
}
}