You are here

function mailchimp_update_6203 in Mailchimp 6.2

Implementation of hook_update_N().

Convert 'mailchimp_lists' to a normal array.

File

./mailchimp.install, line 94

Code

function mailchimp_update_6203() {
  $ret = array();
  $var = variable_get('mailchimp_lists', array());
  if (is_array($var)) {
    $ret[] = array(
      'success' => TRUE,
      'query' => "The 'mailchimp_lists' variable has already been fixed.",
    );
  }
  else {
    $var = unserialize($var);
    variable_set('mailchimp_lists', $var);
    $ret[] = array(
      'success' => TRUE,
      'query' => "The 'mailchimp_lists' variable has been fixed.",
    );
  }
  return $ret;
}