Index: trunk/kernel/include/custommetadata.php =================================================================== diff -u -r7635 -r8009 --- trunk/kernel/include/custommetadata.php (.../custommetadata.php) (revision 7635) +++ trunk/kernel/include/custommetadata.php (.../custommetadata.php) (revision 8009) @@ -109,11 +109,12 @@ $d =& $this->GetItemRefByIndex($i); if($d->Get("CustomFieldId")==$id) { - $found=TRUE; + $found = true; break; } } - return $found ? ($return_index ? $i : $d) : false; + + return $found ? ($return_index ? $i : $d) : $found; } function SaveData($main_prefix, $resource_id)