You are here

function googlenews_update_6000 in Google News sitemap 6

Same name and namespace in other branches
  1. 7 googlenews.install \googlenews_update_6000()

Fix the googlenews_category variable.

File

./googlenews.install, line 19
Install, update, and uninstall functions for the googlenews module.

Code

function googlenews_update_6000() {
  $ret = array();
  $node_types = variable_get('googlenews_category', array());
  if (!empty($node_types['_gnall'])) {
    $node_types = array_keys(node_get_types('names'));
  }
  else {
    unset($node_types['_gnall']);
    $node_types = array_keys(array_filter($node_types));
  }
  variable_set('googlenews_node_types', $node_types);
  variable_del('googlenews_category');
  return $ret;
}