You are here

function flexslider_update_7001 in Flex Slider 7

Same name and namespace in other branches
  1. 7.2 flexslider.install \flexslider_update_7001()

Implements hook_update_N().

Remove/Update table fields to better suit Flex Slider

File

./flexslider.install, line 119
Installation actions for Flex Slider

Code

function flexslider_update_7001(&$sandbox) {
  $field_new = array(
    'description' => 'The image style for normal images.',
    'type' => 'varchar',
    'length' => 255,
    'not null' => TRUE,
    'default' => 'flexslider_full',
  );

  // Change the default image style
  db_change_field('flexslider_optionset', 'imagestyle_normal', $field_new, array());

  // Drop the unused table column
  db_drop_field('flexslider_optionset', 'imagestyle_thumb');
}