Index: modules/tracker/tracker.pages.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/tracker/tracker.pages.inc,v retrieving revision 1.5 diff -u -r1.5 tracker.pages.inc --- modules/tracker/tracker.pages.inc 28 Nov 2007 10:29:20 -0000 1.5 +++ modules/tracker/tracker.pages.inc 17 Feb 2008 07:17:06 -0000 @@ -50,7 +50,7 @@ } $rows[] = array( - check_plain(node_get_types('name', $node->type)), + check_plain(node_get_name($node)), l($node->title, "node/$node->nid") .' '. theme('mark', node_mark($node->nid, $node->changed)), theme('username', $node), array('class' => 'replies', 'data' => $comments), Index: modules/node/node.pages.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/node/node.pages.inc,v retrieving revision 1.28 diff -u -r1.28 node.pages.inc --- modules/node/node.pages.inc 3 Feb 2008 19:26:10 -0000 1.28 +++ modules/node/node.pages.inc 17 Feb 2008 07:16:46 -0000 @@ -452,7 +452,7 @@ node_save($node); $node_link = l(t('view'), 'node/'. $node->nid); $watchdog_args = array('@type' => $node->type, '%title' => $node->title); - $t_args = array('@type' => node_get_types('name', $node), '%title' => $node->title); + $t_args = array('@type' => node_get_name($node), '%title' => $node->title); if ($insert) { watchdog('content', '@type: added %title.', $watchdog_args, WATCHDOG_NOTICE, $node_link); @@ -581,7 +581,7 @@ node_save($node_revision); watchdog('content', '@type: reverted %title revision %revision.', array('@type' => $node_revision->type, '%title' => $node_revision->title, '%revision' => $node_revision->vid)); - drupal_set_message(t('@type %title has been reverted back to the revision from %revision-date.', array('@type' => node_get_types('name', $node_revision), '%title' => $node_revision->title, '%revision-date' => format_date($node_revision->revision_timestamp)))); + drupal_set_message(t('@type %title has been reverted back to the revision from %revision-date.', array('@type' => node_get_name($node_revision), '%title' => $node_revision->title, '%revision-date' => format_date($node_revision->revision_timestamp)))); $form_state['redirect'] = 'node/'. $node_revision->nid .'/revisions'; } @@ -595,7 +595,7 @@ db_query("DELETE FROM {node_revisions} WHERE nid = %d AND vid = %d", $node_revision->nid, $node_revision->vid); node_invoke_nodeapi($node_revision, 'delete revision'); watchdog('content', '@type: deleted %title revision %revision.', array('@type' => $node_revision->type, '%title' => $node_revision->title, '%revision' => $node_revision->vid)); - drupal_set_message(t('Revision from %revision-date of @type %title has been deleted.', array('%revision-date' => format_date($node_revision->revision_timestamp), '@type' => node_get_types('name', $node_revision), '%title' => $node_revision->title))); + drupal_set_message(t('Revision from %revision-date of @type %title has been deleted.', array('%revision-date' => format_date($node_revision->revision_timestamp), '@type' => node_get_name($node_revision), '%title' => $node_revision->title))); $form_state['redirect'] = 'node/'. $node_revision->nid; if (db_result(db_query('SELECT COUNT(vid) FROM {node_revisions} WHERE nid = %d', $node_revision->nid)) > 1) { $form_state['redirect'] .= '/revisions'; Index: modules/node/node.module =================================================================== RCS file: /cvs/drupal/drupal/modules/node/node.module,v retrieving revision 1.947 diff -u -r1.947 node.module --- modules/node/node.module 3 Feb 2008 19:41:47 -0000 1.947 +++ modules/node/node.module 17 Feb 2008 07:16:41 -0000 @@ -51,12 +51,12 @@ return '

'. t('The revisions let you track differences between multiple versions of a post.') .'

'; case 'node/%/edit': $node = node_load($arg[1]); - $type = node_get_types('type', $node->type); + $type = node_get_type($node); return (!empty($type->help) ? '

'. filter_xss_admin($type->help) .'

' : ''); } if ($arg[0] == 'node' && $arg[1] == 'add' && $arg[2]) { - $type = node_get_types('type', str_replace('-', '_', $arg[2])); + $type = node_get_type(str_replace('-', '_', $arg[2])); return (!empty($type->help) ? '

'. filter_xss_admin($type->help) .'

' : ''); } } @@ -392,32 +392,60 @@ } /** - * Builds a list of available node types, and returns all of part of this list - * in the specified format. - * - * @param $op - * The format in which to return the list. When this is set to 'type', - * 'module', or 'name', only the specified node type is returned. When set to - * 'types' or 'names', all node types are returned. - * @param $node - * A node object, array, or string that indicates the node type to return. - * Leave at default value (NULL) to return a list of all node types. + * Builds a list of all the available node types + * * @param $reset - * Whether or not to reset this function's internal cache (defaults to + * Whether or not to reset the node list (defaults to * FALSE). - * - * @return - * Either an array of all available node types, or a single node type, in a - * variable format. Returns FALSE if the node type is not found. */ -function node_get_types($op = 'types', $node = NULL, $reset = FALSE) { - static $_node_types, $_node_names; +function node_get_types($reset = FALSE) { + list($_node_types, $_node_names) = _node_types_build($reset); + return $_node_types; +} - if ($reset || !isset($_node_types)) { - list($_node_types, $_node_names) = _node_types_build(); +/** + * returns false if the node type does not exist. Otherwise returns the nodes type. + * + * @param $type + * A string that indicates the node type to return. + */ + function node_get_type($node){ + list($_node_types, $_node_names) = _node_types_build(); + if ($node) { + if (is_array($node)) { + $type = $node['type']; + } + elseif (is_object($node)) { + $type = $node->type; + } + elseif (is_string($node)) { + $type = $node; + } + if (!isset($_node_types[$type])) { + return FALSE; + } } - - if ($node) { + return isset($_node_types[$type]) ? $_node_types[$type] : FALSE; + } + + /** + * returns a list of available node names. + */ + function node_get_names(){ + list($_node_types, $_node_names) = _node_types_build(); + + return $_node_names; + } + + /** + * returns false if the node name does not exist. Otherwise returns the nodes name. + * + * @param $type + * A string that indicates the node type to return the name for. + */ + function node_get_name($node){ + list($_node_types, $_node_names) = _node_types_build(); + if ($node) { if (is_array($node)) { $type = $node['type']; } @@ -431,19 +459,34 @@ return FALSE; } } - switch ($op) { - case 'types': - return $_node_types; - case 'type': - return isset($_node_types[$type]) ? $_node_types[$type] : FALSE; - case 'module': - return isset($_node_types[$type]->module) ? $_node_types[$type]->module : FALSE; - case 'names': - return $_node_names; - case 'name': - return isset($_node_names[$type]) ? $_node_names[$type] : FALSE; + return isset($_node_names[$type]) ? $_node_names[$type] : FALSE; + } + + /** + * returns false if the node module does not exist. Otherwise returns the modules name. + * + * @param $type + * A string that indicates the node type to return the module for. + */ + function node_get_module($node){ + list($_node_types, $_node_names) = _node_types_build(); + if ($node) { + if (is_array($node)) { + $type = $node['type']; + } + elseif (is_object($node)) { + $type = $node->type; + } + elseif (is_string($node)) { + $type = $node; + } + if (!isset($_node_types[$type])) { + return FALSE; + } } -} + + return isset($_node_types[$type]->module) ? $_node_types[$type]->module : FALSE; + } /** * Resets the database cache of node types, and saves all new or non-modified @@ -451,8 +494,7 @@ */ function node_types_rebuild() { _node_types_build(); - - $node_types = node_get_types('types', NULL, TRUE); + $node_types = node_get_types(TRUE); foreach ($node_types as $type => $info) { if (!empty($info->is_new)) { @@ -462,7 +504,6 @@ node_type_delete($info->type); } } - _node_types_build(); } @@ -510,7 +551,7 @@ * The machine-readable name of the node type to be deleted. */ function node_type_delete($type) { - $info = node_get_types('type', $type); + $info = node_get_type($type); db_query("DELETE FROM {node_type} WHERE type = '%s'", $type); module_invoke_all('node_type', 'delete', $info); } @@ -538,38 +579,41 @@ * by comparing this information with the node types in the {node_type} table. * */ -function _node_types_build() { - $_node_types = array(); - $_node_names = array(); - - $info_array = module_invoke_all('node_info'); - foreach ($info_array as $type => $info) { - $info['type'] = $type; - $_node_types[$type] = (object) _node_type_set_defaults($info); - $_node_names[$type] = $info['name']; - } - - $type_result = db_query(db_rewrite_sql('SELECT nt.type, nt.* FROM {node_type} nt ORDER BY nt.type ASC', 'nt', 'type')); - while ($type_object = db_fetch_object($type_result)) { - // Check for node types from disabled modules and mark their types for removal. - // Types defined by the node module in the database (rather than by a separate - // module using hook_node_info) have a module value of 'node'. - if ($type_object->module != 'node' && empty($info_array[$type_object->type])) { - $type_object->disabled = TRUE; - } - if (!isset($_node_types[$type_object->type]) || $type_object->modified) { - $_node_types[$type_object->type] = $type_object; - $_node_names[$type_object->type] = $type_object->name; - - if ($type_object->type != $type_object->orig_type) { - unset($_node_types[$type_object->orig_type]); - unset($_node_names[$type_object->orig_type]); +function _node_types_build($reset = false) { + static $_node_types, $_node_names; + + if ($reset == TRUE || !isset($_node_types)) { + $_node_types = array(); + $_node_names = array(); + + $info_array = module_invoke_all('node_info'); + foreach ($info_array as $type => $info) { + $info['type'] = $type; + $_node_types[$type] = (object) _node_type_set_defaults($info); + $_node_names[$type] = $info['name']; + } + + $type_result = db_query(db_rewrite_sql('SELECT nt.type, nt.* FROM {node_type} nt ORDER BY nt.type ASC', 'nt', 'type')); + while ($type_object = db_fetch_object($type_result)) { + // Check for node types from disabled modules and mark their types for removal. + // Types defined by the node module in the database (rather than by a separate + // module using hook_node_info) have a module value of 'node'. + if ($type_object->module != 'node' && empty($info_array[$type_object->type])) { + $type_object->disabled = TRUE; + } + if (!isset($_node_types[$type_object->type]) || $type_object->modified) { + $_node_types[$type_object->type] = $type_object; + $_node_names[$type_object->type] = $type_object->name; + + if ($type_object->type != $type_object->orig_type) { + unset($_node_types[$type_object->orig_type]); + unset($_node_names[$type_object->orig_type]); + } } } + asort($_node_names); } - asort($_node_names); - return array($_node_types, $_node_names); } @@ -624,7 +668,7 @@ * TRUE iff the $hook exists in the node type of $node. */ function node_hook(&$node, $hook) { - $module = node_get_types('module', $node); + $module = node_get_module($node); if ($module == 'node') { $module = 'node_content'; // Avoid function name collisions. } @@ -645,7 +689,7 @@ */ function node_invoke(&$node, $hook, $a2 = NULL, $a3 = NULL, $a4 = NULL) { if (node_hook($node, $hook)) { - $module = node_get_types('module', $node); + $module = node_get_module($node); if ($module == 'node') { $module = 'node_content'; // Avoid function name collisions. } @@ -777,7 +821,7 @@ function node_validate($node, $form = array()) { // Convert the node to an object, if necessary. $node = (object)$node; - $type = node_get_types('type', $node); + $type = node_get_type($node); // Make sure the body has the minimum number of words. // TODO : use a better word counting algorithm that will work in other languages @@ -978,7 +1022,7 @@ search_wipe($node->nid, 'node'); } watchdog('content', '@type: deleted %title.', array('@type' => $node->type, '%title' => $node->title)); - drupal_set_message(t('@type %title has been deleted.', array('@type' => node_get_types('name', $node), '%title' => $node->title))); + drupal_set_message(t('@type %title has been deleted.', array('@type' => node_get_name($node), '%title' => $node->title))); } } @@ -1279,7 +1323,7 @@ $extra = node_invoke_nodeapi($node, 'search result'); $results[] = array( 'link' => url('node/'. $item->sid, array('absolute' => TRUE)), - 'type' => check_plain(node_get_types('name', $node)), + 'type' => check_plain(node_get_name($node)), 'title' => $node->title, 'user' => theme('username', $node), 'date' => $node->changed, @@ -1469,7 +1513,7 @@ 'access arguments' => array('access content'), 'type' => MENU_CALLBACK, ); - foreach (node_get_types('types', NULL, TRUE) as $type) { + foreach (node_get_types(TRUE) as $type) { $type_url_str = str_replace('_', '-', $type->type); $items['node/add/'. $type_url_str] = array( 'title' => drupal_ucfirst($type->name), @@ -1854,7 +1898,7 @@ } // Node types: - $types = array_map('check_plain', node_get_types('names')); + $types = array_map('check_plain', node_get_names()); $form['advanced']['type'] = array( '#type' => 'checkboxes', '#title' => t('Only of the type(s)'), @@ -1991,7 +2035,7 @@ // Can't use node_invoke(), because the access hook takes the $op parameter // before the $node parameter. - $module = node_get_types('module', $node); + $module = node_get_module($node); if ($module == 'node') { $module = 'node_content'; // Avoid function name collisions. } @@ -2403,7 +2447,9 @@ * Implementation of hook_form(). */ function node_content_form($node, $form_state) { - $type = node_get_types('type', $node); + + $type = node_get_type($node); + $form = array(); if ($type->has_title) { @@ -2582,7 +2628,7 @@ */ function node_publish_action(&$node, $context = array()) { $node->status = 1; - watchdog('action', 'Set @type %title to published.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); + watchdog('action', 'Set @type %title to published.', array('@type' => node_get_name($node), '%title' => $node->title)); } /** @@ -2591,7 +2637,7 @@ */ function node_unpublish_action(&$node, $context = array()) { $node->status = 0; - watchdog('action', 'Set @type %title to unpublished.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); + watchdog('action', 'Set @type %title to unpublished.', array('@type' => node_get_name($node), '%title' => $node->title)); } /** @@ -2600,7 +2646,7 @@ */ function node_make_sticky_action(&$node, $context = array()) { $node->sticky = 1; - watchdog('action', 'Set @type %title to sticky.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); + watchdog('action', 'Set @type %title to sticky.', array('@type' => node_get_name($node), '%title' => $node->title)); } /** @@ -2609,7 +2655,7 @@ */ function node_make_unsticky_action(&$node, $context = array()) { $node->sticky = 0; - watchdog('action', 'Set @type %title to unsticky.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); + watchdog('action', 'Set @type %title to unsticky.', array('@type' => node_get_name($node), '%title' => $node->title)); } /** @@ -2618,7 +2664,7 @@ */ function node_promote_action(&$node, $context = array()) { $node->promote = 1; - watchdog('action', 'Promoted @type %title to front page.', array('@type' => node_get_types('type', $node), '%title' => $node->title)); + watchdog('action', 'Promoted @type %title to front page.', array('@type' => node_get_type($node), '%title' => $node->title)); } /** @@ -2627,7 +2673,7 @@ */ function node_unpromote_action(&$node, $context = array()) { $node->promote = 0; - watchdog('action', 'Removed @type %title from front page.', array('@type' => node_get_types('type', $node), '%title' => $node->title)); + watchdog('action', 'Removed @type %title from front page.', array('@type' => node_get_type($node), '%title' => $node->title)); } /** @@ -2636,7 +2682,7 @@ */ function node_save_action($node) { node_save($node); - watchdog('action', 'Saved @type %title', array('@type' => node_get_types('type', $node), '%title' => $node->title)); + watchdog('action', 'Saved @type %title', array('@type' => node_get_type($node), '%title' => $node->title)); } /** @@ -2646,7 +2692,7 @@ function node_assign_owner_action(&$node, $context) { $node->uid = $context['owner_uid']; $owner_name = db_result(db_query("SELECT name FROM {users} WHERE uid = %d", $context['owner_uid'])); - watchdog('action', 'Changed owner of @type %title to uid %name.', array('@type' => node_get_types('type', $node), '%title' => $node->title, '%name' => $owner_name)); + watchdog('action', 'Changed owner of @type %title to uid %name.', array('@type' => node_get_type($node), '%title' => $node->title, '%name' => $owner_name)); } function node_assign_owner_action_form($context) { @@ -2726,7 +2772,7 @@ foreach ($context['keywords'] as $keyword) { if (strstr(node_view(drupal_clone($node)), $keyword) || strstr($node->title, $keyword)) { $node->status = 0; - watchdog('action', 'Set @type %title to unpublished.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); + watchdog('action', 'Set @type %title to unpublished.', array('@type' => node_get_name($node), '%title' => $node->title)); break; } } Index: modules/node/node.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/node/node.admin.inc,v retrieving revision 1.20 diff -u -r1.20 node.admin.inc --- modules/node/node.admin.inc 6 Feb 2008 19:38:27 -0000 1.20 +++ modules/node/node.admin.inc 17 Feb 2008 07:16:31 -0000 @@ -156,7 +156,7 @@ ); } - $filters['type'] = array('title' => t('type'), 'options' => node_get_types('names')); + $filters['type'] = array('title' => t('type'), 'options' => node_get_names()); // The taxonomy filter if ($taxonomy = module_invoke('taxonomy', 'form_all', 1)) { @@ -495,7 +495,7 @@ $nodes[$node->nid] = ''; $options = empty($node->language) ? array() : array('language' => $languages[$node->language]); $form['title'][$node->nid] = array('#value' => l($node->title, 'node/'. $node->nid, $options) .' '. theme('mark', node_mark($node->nid, $node->changed))); - $form['name'][$node->nid] = array('#value' => check_plain(node_get_types('name', $node))); + $form['name'][$node->nid] = array('#value' => check_plain(node_get_name($node))); $form['username'][$node->nid] = array('#value' => theme('username', $node)); $form['status'][$node->nid] = array('#value' => ($node->status ? t('published') : t('not published'))); if ($multilanguage) { Index: modules/node/content_types.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/node/content_types.inc,v retrieving revision 1.50 diff -u -r1.50 content_types.inc --- modules/node/content_types.inc 27 Jan 2008 18:03:05 -0000 1.50 +++ modules/node/content_types.inc 17 Feb 2008 07:16:30 -0000 @@ -11,12 +11,14 @@ */ function node_overview_types() { $types = node_get_types(); - $names = node_get_types('names'); + $names = node_get_names(); + $header = array(t('Name'), t('Type'), t('Description'), array('data' => t('Operations'), 'colspan' => '2')); $rows = array(); foreach ($names as $key => $name) { $type = $types[$key]; + if (node_hook($type, 'form')) { $type_url_str = str_replace('_', '-', $type->type); $row = array( @@ -224,7 +226,7 @@ // Work out what the type was before the user submitted this form $old_type = trim($form_state['values']['old_type']); - $types = node_get_types('names'); + $types = node_get_names(); if (!$form_state['values']['locked']) { if (isset($types[$type->type]) && $type->type != $old_type) { Index: modules/system/system.module =================================================================== RCS file: /cvs/drupal/drupal/modules/system/system.module,v retrieving revision 1.590 diff -u -r1.590 system.module --- modules/system/system.module 14 Feb 2008 18:34:21 -0000 1.590 +++ modules/system/system.module 17 Feb 2008 07:17:04 -0000 @@ -1717,7 +1717,7 @@ $variables += array( '%uid' => $node->uid, '%node_url' => url('node/'. $node->nid, array('absolute' => TRUE)), - '%node_type' => node_get_types('name', $node), + '%node_type' => node_get_name($node), '%title' => $node->title, '%teaser' => $node->teaser, '%body' => $node->body, @@ -1791,7 +1791,7 @@ $variables = array_merge($variables, array( '%uid' => $node->uid, '%node_url' => url('node/'. $node->nid, array('absolute' => TRUE)), - '%node_type' => check_plain(node_get_types('name', $node)), + '%node_type' => check_plain(node_get_name($node)), '%title' => filter_xss($node->title), '%teaser' => filter_xss($node->teaser), '%body' => filter_xss($node->body), Index: modules/system/system.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/system/system.admin.inc,v retrieving revision 1.63 diff -u -r1.63 system.admin.inc --- modules/system/system.admin.inc 4 Feb 2008 12:35:48 -0000 1.63 +++ modules/system/system.admin.inc 17 Feb 2008 07:16:59 -0000 @@ -420,7 +420,7 @@ ); // Toggle node display. - $node_types = node_get_types('names'); + $node_types = node_get_names(); if ($node_types) { $form['node_info'] = array( '#type' => 'fieldset', Index: modules/blog/blog.module =================================================================== RCS file: /cvs/drupal/drupal/modules/blog/blog.module,v retrieving revision 1.298 diff -u -r1.298 blog.module --- modules/blog/blog.module 6 Feb 2008 19:38:27 -0000 1.298 +++ modules/blog/blog.module 17 Feb 2008 07:16:24 -0000 @@ -76,7 +76,7 @@ function blog_form(&$node) { global $nid; $iid = isset($_GET['iid']) ? (int)$_GET['iid'] : 0; - $type = node_get_types('type', $node); + $type = node_get_type($node); if (empty($node->body)) { Index: modules/poll/poll.module =================================================================== RCS file: /cvs/drupal/drupal/modules/poll/poll.module,v retrieving revision 1.263 diff -u -r1.263 poll.module --- modules/poll/poll.module 15 Jan 2008 07:57:46 -0000 1.263 +++ modules/poll/poll.module 17 Feb 2008 07:16:49 -0000 @@ -186,7 +186,7 @@ $admin = user_access('administer nodes') || user_access('edit any poll content') || (user_access('edit own poll content') && $user->uid == $node->uid); - $type = node_get_types('type', $node); + $type = node_get_type($node); $form = array( '#cache' => TRUE, Index: modules/taxonomy/taxonomy.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/taxonomy/taxonomy.admin.inc,v retrieving revision 1.24 diff -u -r1.24 taxonomy.admin.inc --- modules/taxonomy/taxonomy.admin.inc 14 Feb 2008 18:41:16 -0000 1.24 +++ modules/taxonomy/taxonomy.admin.inc 17 Feb 2008 07:17:06 -0000 @@ -19,7 +19,7 @@ foreach ($vocabularies as $vocabulary) { $types = array(); foreach ($vocabulary->nodes as $type) { - $node_type = node_get_types('name', $type); + $node_type = node_get_name($type); $types[] = $node_type ? check_plain($node_type) : check_plain($type); } $form[$vocabulary->vid]['#vocabulary'] = (array)$vocabulary; @@ -148,7 +148,7 @@ $form['content_types']['nodes'] = array('#type' => 'checkboxes', '#title' => t('Content types'), '#default_value' => $edit['nodes'], - '#options' => array_map('check_plain', node_get_types('names')), + '#options' => array_map('check_plain', node_get_names()), '#description' => t('Select content types to categorize using this vocabulary.'), ); $form['settings'] = array( Index: modules/forum/forum.module =================================================================== RCS file: /cvs/drupal/drupal/modules/forum/forum.module,v retrieving revision 1.450 diff -u -r1.450 forum.module --- modules/forum/forum.module 8 Feb 2008 03:10:32 -0000 1.450 +++ modules/forum/forum.module 17 Feb 2008 07:16:29 -0000 @@ -443,7 +443,7 @@ * Implementation of hook_form(). */ function forum_form(&$node, $form_state) { - $type = node_get_types('type', $node); + $type = node_get_type($node); $form['title'] = array('#type' => 'textfield', '#title' => check_plain($type->title_label), '#default_value' => !empty($node->title) ? $node->title : '', '#required' => TRUE, '#weight' => -5); if (!empty($node->nid)) { @@ -674,7 +674,7 @@ if (node_access('create', $type)) { // Fetch the "General" name of the content type; // Push the link with title and url to the array. - $forum_types[$type] = array('title' => t('Post new @node_type', array('@node_type' => node_get_types('name', $type))), 'href' => 'node/add/'. str_replace('_', '-', $type) .'/'. $variables['tid']); + $forum_types[$type] = array('title' => t('Post new @node_type', array('@node_type' => node_get_name($type))), 'href' => 'node/add/'. str_replace('_', '-', $type) .'/'. $variables['tid']); } } Index: modules/blogapi/blogapi.module =================================================================== RCS file: /cvs/drupal/drupal/modules/blogapi/blogapi.module,v retrieving revision 1.116 diff -u -r1.116 blogapi.module --- modules/blogapi/blogapi.module 12 Feb 2008 13:54:43 -0000 1.116 +++ modules/blogapi/blogapi.module 17 Feb 2008 07:16:25 -0000 @@ -557,7 +557,7 @@ } function blogapi_admin_settings() { - $node_types = array_map('check_plain', node_get_types('names')); + $node_types = array_map('check_plain', node_get_names()); $defaults = isset($node_types['blog']) ? array('blog' => 1) : array(); $form['blogapi_node_types'] = array( '#type' => 'checkboxes', Index: modules/book/book.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/book/book.admin.inc,v retrieving revision 1.8 diff -u -r1.8 book.admin.inc --- modules/book/book.admin.inc 8 Jan 2008 10:35:41 -0000 1.8 +++ modules/book/book.admin.inc 17 Feb 2008 07:16:26 -0000 @@ -27,7 +27,7 @@ * @ingroup forms */ function book_admin_settings() { - $types = node_get_types('names'); + $types = node_get_names(); $form['book_allowed_types'] = array( '#type' => 'checkboxes', '#title' => t('Allowed book outline types'), Index: .project =================================================================== RCS file: .project diff -N .project --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ .project 1 Jan 1970 00:00:00 -0000 @@ -0,0 +1,11 @@ + + + drupal + + + + + + + +