fixed old search (read) for no filter given

This commit is contained in:
Ralf Becker 2006-05-17 04:15:58 +00:00
parent 8cbca0bfd2
commit d03b888c94

View File

@ -91,12 +91,15 @@ class contacts extends bocontacts
{
//echo "<p>contacts::old_read($start,$limit,".print_r($fields,true).",$query,'$filter','$sort','$order',$lastmod,$cquery)</p>\n";
$sfilter = array();
if ($filter)
{
foreach(explode(',',$filter) as $expr)
{
list($col,$value) = explode('=',$expr);
$sfilter[$col] = $value;
}
}
if ($lastmod != -1)
{
$sfilter[] = 'contact_modified > '.(int)$lastmod;