function uc_product_content_fieldapi in Ubercart 6.2
Implements hook_content_fieldapi().
Resets a content type's default image field setting when that field instance is removed.
File
- uc_product/
uc_product.module, line 1007 - The product module for Ubercart.
Code
function uc_product_content_fieldapi($op, $field) {
switch ($op) {
case 'delete instance':
if ($field->field_name == variable_get('uc_image_' . $field->type_name, NULL)) {
variable_set('uc_image_' . $field->type_name, NULL);
}
break;
}
}