You are here

function notifications_update_6017 in Notifications 6.4

Drop unused columns and add fields for scheduled subscriptions

File

./notifications.install, line 525

Code

function notifications_update_6017() {
  $ret = array();
  if (db_column_exists('notifications_sent', 'send_method')) {
    db_drop_field($ret, 'notifications_sent', 'send_method');
  }
  db_add_field($ret, 'notifications_sent', 'counter', array(
    'type' => 'int',
    'unsigned' => TRUE,
    'not null' => TRUE,
    'default' => 0,
  ));
  db_add_field($ret, 'notifications_queue', 'send_time', array(
    'type' => 'int',
    'unsigned' => TRUE,
    'not null' => TRUE,
    'default' => 0,
  ));
  return $ret;
}