function node_update_8008

Rename default menu names.

Related topics

File

drupal/core/modules/node/node.install, line 743
Install, update and uninstall functions for the node module.

Code

function node_update_8008() {

  // System menu's new block deltas are prefixed with 'menu-'.
  $map = array(
    'navigation' => 'menu-tools',
    'management' => 'menu-admin',
    'user-menu' => 'menu-account',
    'main-menu' => 'menu-main',
  );
  foreach ($map as $old => $new) {
    db_update('block_node_type')
      ->condition('module', 'system')
      ->condition('delta', $old)
      ->fields(array(
      'delta' => $new,
    ))
      ->execute();
  }
}