Bug correction in Storage class

This commit is contained in:
Phyks 2013-09-06 18:09:19 +02:00
parent 2582594b37
commit 69fc984bab

View File

@ -121,7 +121,7 @@ class Storage {
} }
foreach($value as $value_array) { foreach($value as $value_array) {
if($value_array == 'AND' || $value_array = 'OR') { if($value_array == 'AND' || $value_array == 'OR') {
$query .= ' '.$value_array.' '; $query .= ' '.$value_array.' ';
continue; continue;
} }
@ -150,10 +150,10 @@ class Storage {
if($value_array == 'AND' || $value_array == 'OR') if($value_array == 'AND' || $value_array == 'OR')
continue; continue;
if(substr($value, 0, 1) == ">" || substr($value, 0, 1) == "<") if(substr($value_array, 0, 1) == ">" || substr($value_array, 0, 1) == "<")
$query->bindParam(':'.$field, substr($value, 0, 1)); $query->bindParam(':'.$field, substr($value_array, 0, 1));
else else
$query->bindParam(':'.$field, $value); $query->bindParam(':'.$field, $value_array);
} }
} }
} }