You are here

function vud_update_6200 in Vote Up/Down 7

Same name and namespace in other branches
  1. 6.3 vud.install \vud_update_6200()
  2. 6.2 vud.install \vud_update_6200()

First update - Deprecate UpDown in favor of Vote Up/Down.

File

./vud.install, line 19
Install, update and uninstall functions for the Vote Up/Down core module.

Code

function vud_update_6200() {
  $ret = array();
  $ret[] = update_sql("DELETE FROM {variable} WHERE name LIKE('updown%')");
  $ret[] = update_sql("UPDATE {votingapi_vote} SET tag = 'vote' WHERE tag LIKE('updown')");
  $ret[] = update_sql("UPDATE {votingapi_cache} SET tag = 'vote' WHERE tag LIKE('updown')");
  if (module_exists('updown')) {
    $ret[] = drupal_uninstall_schema('updown');
    drupal_uninstall_module('updown');
  }
  if (module_exists('updown_node')) {
    $ret[] = drupal_uninstall_schema('updown_node');
    drupal_uninstall_module('updown_node');
  }
  return $ret;
}