You are here

function xmlsitemap_engines_update_6201 in XML sitemap 6.2

Cleanup 6.x-1.x variables and weights.

File

xmlsitemap_engines/xmlsitemap_engines.install, line 94
Install, update and uninstall functions for the xmlsitemap_engines module.

Code

function xmlsitemap_engines_update_6201() {
  $ret = array();
  $engines = array(
    'google',
    'bing',
    'live',
    'yahoo',
    'ask',
    'moreover',
  );
  foreach ($engines as $engine) {
    db_query("DELETE FROM {variable} WHERE name LIKE 'xmlsitemap_engines_%s_%%'", $engine);
  }
  variable_del('xmlsitemap_engines_cron_submit_frequency');
  variable_del('xmlsitemap_engines_cron_timestamp_submit');
  variable_del('xmlsitemap_engines_submit');
  $ret[] = update_sql("UPDATE {system} SET weight = 2 WHERE type = 'module' AND name = 'xmlsitemap_engines'");
  return $ret;
}