You are here

function computed_field_content_is_empty in Computed Field 6

Same name and namespace in other branches
  1. 5 computed_field.module \computed_field_content_is_empty()

Implementation of cck hook_content_is_empty().

File

./computed_field.module, line 421

Code

function computed_field_content_is_empty($item, $field) {
  if ($field['data_type'] == 'int' || $field['data_type'] == 'float') {
    return !is_numeric($item['value']);
  }
  return empty($item['value']);
}