Index: modules/comment/comment.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/comment/comment.module,v
retrieving revision 1.534
diff -u -d -F^\s*function -r1.534 comment.module
--- modules/comment/comment.module	1 Apr 2007 05:04:19 -0000	1.534
+++ modules/comment/comment.module	3 Apr 2007 21:42:12 -0000
@@ -379,7 +379,7 @@ function comment_form_alter(&$form, $for
     $form['workflow']['comment'] = array(
       '#type' => 'radios',
       '#title' => t('Default comment setting'),
-      '#default_value' => variable_get('comment_'. $form['#node_type']->type, COMMENT_NODE_READ_WRITE),
+      '#default_value' => $form['#node_type']->settings['comment'],
       '#options' => array(t('Disabled'), t('Read only'), t('Read/Write')),
       '#description' => t('Users with the <em>administer comments</em> permission will be able to override this setting.'),
     );
@@ -453,6 +453,19 @@ function comment_nodeapi(&$node, $op, $a
 }
 
 /**
+ * Implementation of hook_node_type().
+ */
+function comment_node_type($op, $info) {
+  switch ($op) {
+    case 'defaults':
+      return array(
+        'comment' => COMMENT_NODE_READ_WRITE,
+      );
+      break;
+  }
+}
+
+/**
  * Implementation of hook_user().
  */
 function comment_user($type, $edit, &$user, $category = NULL) {
Index: modules/node/content_types.inc
===================================================================
RCS file: /cvs/drupal/drupal/modules/node/content_types.inc,v
retrieving revision 1.27
diff -u -d -F^\s*function -r1.27 content_types.inc
--- modules/node/content_types.inc	27 Mar 2007 05:13:54 -0000	1.27
+++ modules/node/content_types.inc	3 Apr 2007 21:42:13 -0000
@@ -52,18 +52,14 @@ function node_overview_types() {
 function node_type_form($type = NULL) {
   if (!isset($type->type)) {
     $type = new stdClass();
-    $type->type = $type->name = $type->module = $type->description = $type->help = '';
-    $type->min_word_count = 0;
-    $type->has_title = TRUE;
-    $type->has_body = TRUE;
-    $type->title_label = t('Title');
-    $type->body_label = t('Body');
+    $type->type = '';
     $type->custom = TRUE;
-    $type->modified = FALSE;
     $type->locked = FALSE;
   }
+  $type = _node_type_set_defaults($type);
 
-  $form['#node_type'] = $type; // Make the type object available to implementations of hook_form_alter.
+  // Make the type object available to implementations of hook_form_alter.
+  $form['#node_type'] = $type;
 
   $form['identity'] = array(
     '#type' => 'fieldset',
@@ -150,9 +146,16 @@ function node_type_form($type = NULL) {
     '#title' =>t('Workflow'),
     '#collapsible' => TRUE,
   );
+
+  $node_options = array();
+  foreach ($type->settings['node_options'] as $key => $value) {
+    if ($value) {
+      $node_options[] = $key;
+    }
+  }
   $form['workflow']['node_options'] = array('#type' => 'checkboxes',
     '#title' => t('Default options'),
-    '#default_value' => variable_get('node_options_'. $type->type, array('status', 'promote')),
+    '#default_value' => $node_options,
     '#options' => array(
       'status' => t('Published'),
       'promote' => t('Promoted to front page'),
@@ -255,68 +258,45 @@ function node_type_form_validate($form_i
 function node_type_form_submit($form_id, $form_values) {
   $op = isset($form_values['op']) ? $form_values['op'] : '';
 
-  $type = new stdClass();
+  if ($op == t('Delete content type') && isset($form_values['old_type'])) {
+    return 'admin/content/types/'. str_replace('_', '-', $form_values['old_type']) .'/delete';
+  }
 
-  $type->type = trim($form_values['type']);
-  $type->name = trim($form_values['name']);
-  $type->orig_type = trim($form_values['orig_type']);
-  $type->old_type = isset($form_values['old_type']) ? $form_values['old_type'] : $type->type;
+  if (!empty($form_values['old_type'])) {
+    $type = node_get_types('type', $form_values['old_type']);
+  }
+  else {
+    $type = new stdClass();
+    $type->custom = TRUE;
+    $type->locked = FALSE;
+    $type = _node_type_set_defaults($type);
+  }
 
-  $type->description = $form_values['description'];
-  $type->help = $form_values['help'];
-  $type->min_word_count = $form_values['min_word_count'];
-  $type->title_label = $form_values['title_label'];
-  $type->body_label = $form_values['body_label'];
+  foreach (array('type', 'name', 'orig_type', 'description', 'help', 'title_label', 'body_label', 'module', 'custom', 'locked', 'old_type') as $property) {
+    if (isset($form_values[$property])) {
+      $type->$property = $form_values[$property];
+      unset($form_values[$property]);
+    }
+  }
 
   // title_label is required in core; has_title will always be true, unless a
   // module alters the title field.
-  $type->has_title = ($type->title_label != '');
-  $type->has_body = ($type->body_label != '');
-
-  $type->module = !empty($form_values['module']) ? $form_values['module'] : 'node';
-  $type->custom = $form_values['custom'];
+  $type->has_title = !empty($type->title_label);
+  $type->has_body = !empty($type->body_label);
   $type->modified = TRUE;
-  $type->locked = $form_values['locked'];
 
   if ($op == t('Reset to defaults')) {
     node_type_reset($type);
+    drupal_set_message(t('The content type %name has been reset to its default values.', $t_args));
   }
-  elseif ($op == t('Delete content type')) {
-    return 'admin/content/types/'. str_replace('_', '-', $type->old_type) .'/delete';
-  }
-
-  $status = node_type_save($type);
-
-  $variables = $form_values;
+  else {
+    unset($form_values['form_token'], $form_values['op'], $form_values['submit'], $form_values['delete'], $form_values['reset'], $form_values['form_id']);
 
-  // Remove everything that's been saved already - whatever's left is assumed
-  // to be a persistent variable.
-  foreach ($variables as $key => $value) {
-    if (isset($type->$key)) {
-      unset($variables[$key]);
-    }
+    // Save or reset persistent variable values.
+    $type->settings = array_merge($type->settings, $form_values);
   }
 
-  unset($variables['form_token'], $variables['op'], $variables['submit'], $variables['delete'], $variables['reset'], $variables['form_id']);
-
-  // Save or reset persistent variable values.
-  foreach ($variables as $key => $value) {
-    $key .= '_'. $type->type;
-    if ($op == t('Reset to defaults')) {
-      variable_del($key);
-    }
-    else {
-      if (is_array($value)) {
-        $value = array_keys(array_filter($value));
-      }
-      variable_set($key, $value);
-
-      if ($type->old_type != $type->type) {
-        $key = str_replace($type->type, $type->old_type, $key);
-        variable_del($key);
-      }
-    }
-  }
+  $status = node_type_save($type);
 
   node_types_rebuild();
   // menu_rebuild clears the cache, too
@@ -324,11 +304,9 @@ function node_type_form_submit($form_id,
   $t_args = array('%name' => $type->name);
 
   if ($op == t('Reset to defaults')) {
-    drupal_set_message(t('The content type %name has been reset to its default values.', $t_args));
     return;
   }
-
-  if ($status == SAVED_UPDATED) {
+  elseif ($status == SAVED_UPDATED) {
     drupal_set_message(t('The content type %name has been updated.', $t_args));
   }
   elseif ($status == SAVED_NEW) {
@@ -340,19 +318,6 @@ function node_type_form_submit($form_id,
 }
 
 /**
- * Implementation of hook_node_type().
- */
-function node_node_type($op, $info) {
-  if ($op != 'delete' && !empty($info->old_type) && $info->old_type != $info->type) {
-    $update_count = node_type_update_nodes($info->old_type, $info->type);
-
-    if ($update_count) {
-      drupal_set_message(format_plural($update_count, 'Changed the content type of 1 post from %old-type to %type.', 'Changed the content type of @count posts from %old-type to %type.', array('%old-type' => $info->old_type, '%type' => $info->type)));
-    }
-  }
-}
-
-/**
  * Resets all of the relevant fields of a module-defined node type to their
  * default values.
  *
@@ -364,13 +329,14 @@ function node_node_type($op, $info) {
 function node_type_reset(&$type) {
   $info_array = module_invoke_all('node_info');
   if (isset($info_array[$type->orig_type])) {
-    $info = _node_type_set_defaults($info_array[$type->orig_type]);
-    $info['type'] = $type->orig_type;
+    $info = _node_type_set_defaults((object) $info_array[$type->orig_type]);
+    $info->type = $type->orig_type;
 
     foreach ($info as $field => $value) {
       $type->$field = $value;
     }
   }
+  $type->settings = module_invoke_all('node_type', 'defaults', $info);
 }
 
 /**
Index: modules/node/node.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/node/node.module,v
retrieving revision 1.795
diff -u -d -F^\s*function -r1.795 node.module
--- modules/node/node.module	2 Apr 2007 15:15:39 -0000	1.795
+++ modules/node/node.module	3 Apr 2007 21:42:19 -0000
@@ -301,13 +301,17 @@ function node_type_save($info) {
   }
 
   if ($is_existing) {
-    db_query("UPDATE {node_type} SET type = '%s', name = '%s', module = '%s', has_title = %d, title_label = '%s', has_body = %d, body_label = '%s', description = '%s', help = '%s', min_word_count = %d, custom = %d, modified = %d, locked = %d WHERE type = '%s'", $info->type, $info->name, $info->module, $info->has_title, $info->title_label, $info->has_body, $info->body_label, $info->description, $info->help, $info->min_word_count, $info->custom, $info->modified, $info->locked, $existing_type);
+    db_query("UPDATE {node_type} SET type = '%s', name = '%s', module = '%s', has_title = %d, title_label = '%s', has_body = %d, body_label = '%s', description = '%s', help = '%s', min_word_count = %d, custom = %d, modified = %d, locked = %d, settings = '%s' WHERE type = '%s'", $info->type, $info->name, $info->module, $info->has_title, $info->title_label, $info->has_body, $info->body_label, $info->description, $info->help, $info->min_word_count, $info->custom, $info->modified, $info->locked, serialize($info->settings), $existing_type);
+
+    if (!empty($info->old_type) && $info->type != $info->old_type) {
+      module_invoke_all('node_type', 'rename', $info);
+    }
 
     module_invoke_all('node_type', 'update', $info);
     return SAVED_UPDATED;
   }
   else {
-    db_query("INSERT INTO {node_type} (type, name, module, has_title, title_label, has_body, body_label, description, help, min_word_count, custom, modified, locked, orig_type) VALUES ('%s', '%s', '%s', %d, '%s', %d, '%s', '%s', '%s', %d, %d, %d, %d, '%s')", $info->type, $info->name, $info->module, $info->has_title, $info->title_label, $info->has_body, $info->body_label, $info->description, $info->help, $info->min_word_count, $info->custom, $info->modified, $info->locked, $info->orig_type);
+    db_query("INSERT INTO {node_type} (type, name, module, has_title, title_label, has_body, body_label, description, help, min_word_count, custom, modified, locked, orig_type, settings) VALUES ('%s', '%s', '%s', %d, '%s', %d, '%s', '%s', '%s', %d, %d, %d, %d, '%s', '%s')", $info->type, $info->name, $info->module, $info->has_title, $info->title_label, $info->has_body, $info->body_label, $info->description, $info->help, $info->min_word_count, $info->custom, $info->modified, $info->locked, $info->orig_type, serialize($info->settings));
 
     module_invoke_all('node_type', 'insert', $info);
     return SAVED_NEW;
@@ -349,69 +353,95 @@ function node_type_update_nodes($old_typ
  *
  */
 function _node_types_build() {
-  $_node_types = array();
-  $_node_names = array();
+  // Query all modules for node type definitions.
+  $_node_types = module_invoke_all('node_info');
 
-  $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'];
+  // Initialize the module defined node types.
+  foreach ($_node_types as $type => $info) {
+    $_node_types[$type] = (object) $info;
+    $_node_types[$type]->type = $type;
+    // When the node is already in the database, this will get overwritten below.
+    $_node_types[$type]->is_new = TRUE;
   }
 
   $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)) {
-    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;
+  while ($info = db_fetch_object($type_result)) {
+    if (!isset($_node_types[$info->type]) || $info->modified) {
+      $_node_types[$info->type] = $info;
 
-      if ($type_object->type != $type_object->orig_type) {
-        unset($_node_types[$type_object->orig_type]);
-        unset($_node_names[$type_object->orig_type]);
+      // Delete node types from the node info hook that have been renamed.
+      if ($info->type != $info->orig_type) {
+        unset($_node_types[$info->orig_type]);
       }
     }
+    else {
+      unset($_node_types[$info->type]->is_new);
+    }
   }
 
+  $_node_names = array();
+  foreach ($_node_types as $type => $info) {
+    $_node_types[$type] = _node_type_set_defaults($info);
+    $_node_names[$type] = $_node_types[$type]->name;
+  }
   asort($_node_names);
 
   return array($_node_types, $_node_names);
 }
 
 /**
- * Set default values for a node type defined through hook_node_info().
+ * Set default values for a node types.
  */
 function _node_type_set_defaults($info) {
-  if (!isset($info['has_title'])) {
-    $info['has_title'] = TRUE;
-  }
-  if ($info['has_title'] && !isset($info['title_label'])) {
-    $info['title_label'] = t('Title');
-  }
-
-  if (!isset($info['has_body'])) {
-    $info['has_body'] = TRUE;
-  }
-  if ($info['has_body'] && !isset($info['body_label'])) {
-    $info['body_label'] = t('Body');
+  // Fill in default values if they don't exist
+  foreach (array('name' => '', 'module' => 'node', 'description' => '', 'help' => '', 'has_title' => TRUE, 'title_label' => t('Title'), 'has_body' => TRUE, 'body_label' => t('Body'), 'custom' => FALSE, 'modified' => FALSE, 'locked' => TRUE, 'orig_type' => $info->type) as $property => $value) {
+    if (!isset($info->$property)) {
+      $info->$property = $value;
+    }
   }
 
-  if (!isset($info['custom'])) {
-    $info['custom'] = FALSE;
-  }
-  if (!isset($info['modified'])) {
-    $info['modified'] = FALSE;
+  // Unserialize the settings if they are in serialized form
+  if (isset($info->settings) && is_string($info->settings)) {
+    $info->settings = unserialize($info->settings);
   }
-  if (!isset($info['locked'])) {
-    $info['locked'] = TRUE;
+  if (!isset($info->settings) || !is_array($info->settings)) {
+    $info->settings = array();
   }
 
-  $info['orig_type'] = $info['type'];
-  $info['is_new'] = TRUE;
+  // Allow modules to set default values in the node type object.
+  $settings = module_invoke_all('node_type', 'defaults', $info);
+  $info->settings = $info->settings + $settings;
 
   return $info;
 }
 
 /**
+ * Implementation of hook_node_type().
+ */
+function node_node_type($op, $info) {
+  switch ($op) {
+    case 'defaults':
+      return array(
+        'node_options' => array(
+          'status' => TRUE,
+          'promote' => TRUE,
+          'sticky' => FALSE,
+          'revision' => FALSE,
+        ),
+      );
+      break;
+    case 'rename':
+      // Change the type of nodes in the node table when the node type changes.
+      $update_count = node_type_update_nodes($info->old_type, $info->type);
+
+      if ($update_count) {
+        drupal_set_message(format_plural($update_count, 'Changed the content type of 1 post from %old-type to %type.', 'Changed the content type of @count posts from %old-type to %type.', array('%old-type' => $info->old_type, '%type' => $info->type)));
+      }
+      break;
+  }
+}
+
+/**
  * Determine whether a node hook exists.
  *
  * @param &$node
@@ -1960,17 +1990,19 @@ function node_form($node, $form_values =
     $form['title']['#weight'] = -5;
   }
 
-  $node_options = variable_get('node_options_'. $node->type, array('status', 'promote'));
+  // Fill in the default node options
+  $type = node_get_types('type', $node->type);
+  foreach ($type->settings['node_options'] as $key => $value) {
+    if (!isset($node->$key)) {
+      $node->$key = (bool) $value;
+    }
+  }
+
   // If this is a new node, fill in the default values.
   if (!isset($node->nid)) {
-    foreach (array('status', 'promote', 'sticky') as $key) {
-      $node->$key = in_array($key, $node_options);
-    }
     global $user;
     $node->uid = $user->uid;
   }
-  // Always use the default revision setting.
-  $node->revision = in_array('revision', $node_options);
 
   $form['#node'] = $node;
 
Index: modules/system/system.install
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.install,v
retrieving revision 1.88
diff -u -d -F^\s*function -r1.88 system.install
--- modules/system/system.install	30 Mar 2007 08:47:58 -0000	1.88
+++ modules/system/system.install	3 Apr 2007 21:42:27 -0000
@@ -423,11 +423,11 @@ function system_install() {
         title_label varchar(255) NOT NULL default '',
         has_body tinyint unsigned NOT NULL,
         body_label varchar(255) NOT NULL default '',
-        min_word_count smallint unsigned NOT NULL,
         custom tinyint NOT NULL DEFAULT '0',
         modified tinyint NOT NULL DEFAULT '0',
         locked tinyint NOT NULL DEFAULT '0',
         orig_type varchar(255) NOT NULL default '',
+        settings longtext NOT NULL,
         PRIMARY KEY (type)
       ) /*!40100 DEFAULT CHARACTER SET UTF8 */ ");
 
@@ -908,11 +908,11 @@ function system_install() {
         title_label varchar(255) NOT NULL default '',
         has_body smallint_unsigned NOT NULL,
         body_label varchar(255) NOT NULL default '',
-        min_word_count smallint_unsigned NOT NULL,
         custom smallint NOT NULL DEFAULT '0',
         modified smallint NOT NULL DEFAULT '0',
         locked smallint NOT NULL DEFAULT '0',
         orig_type varchar(255) NOT NULL default '',
+        settings text NO NULL,
         PRIMARY KEY (type)
       )");
 
@@ -3291,7 +3291,7 @@ function system_update_1005() {
   );
 
   foreach ($types as $type) {
-    $type = (object) _node_type_set_defaults($type);
+    $type = _node_type_set_defaults((object) $type);
     node_type_save($type);
   }
 
@@ -3724,6 +3724,52 @@ function system_update_2006() {
 }
 
 /**
+ * Moves content types settings into a dedicated storage in the {node_type}
+ * table rather than storing them in the {variable} table.
+ */
+function system_update_2007() {
+  $ret = array();
+  switch ($GLOBALS['db_type']) {
+    case 'mysql':
+    case 'mysqli':
+    $ret[] = update_sql("ALTER TABLE {node_type} ADD settings longtext NOT NULL");
+      break;
+    case 'pgsql':
+      db_add_column($ret, 'node_type', 'settings', 'text', array('default' => "''", 'not null' => TRUE));
+      break;
+  }
+
+  // Move old content type settings into the new settings column.
+  $types = node_get_types();
+  foreach ($types as $type) {
+    // Migrate comment settings
+    $comment = variable_get('comment_'. $type->type, NULL);
+    if (isset($comment)) {
+      $type->settings['comment'] = $comment;
+      variable_del('comment_'. $type);
+    }
+
+    // Migrate node options
+    $node_options = variable_get('node_options_'. $type->type, NULL);
+    if (isset($node_options)) {
+      foreach ($node_options as $option) {
+        $type->settings['node_options'][$option] = TRUE;
+      }
+      variable_del('node_options_'. $type->type);
+    }
+
+    // Migrate upload.module settings
+    $upload = variable_get('upload_'. $type->type, NULL);
+    if (isset($upload)) {
+      $type->settings['upload'] = $upload;
+      variable_del('upload_'. $type);
+    }
+  }
+
+  return $ret;
+}
+
+/**
  * @} End of "defgroup updates-5.0-to-x.x"
  * The next series of updates should start at 3000.
  */
Index: modules/system/system.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.module,v
retrieving revision 1.460
diff -u -d -F^\s*function -r1.460 system.module
--- modules/system/system.module	27 Mar 2007 05:13:54 -0000	1.460
+++ modules/system/system.module	3 Apr 2007 21:42:33 -0000
@@ -2111,16 +2111,19 @@ function system_theme_settings($key = ''
  * Updates theme settings after a node type change.
  */
 function system_node_type($op, $info) {
-  if ($op == 'update' && !empty($info->old_type) && $info->type != $info->old_type) {
-    $old = 'toggle_node_info_'. $info->old_type;
-    $new = 'toggle_node_info_'. $info->type;
+  switch ($op) {
+    case 'rename':
+      // Move the theme settings over to the new content type.
+      $old = 'toggle_node_info_'. $info->old_type;
+      $new = 'toggle_node_info_'. $info->type;
 
-    $theme_settings = variable_get('theme_settings', array());
-    if (isset($theme_settings[$old])) {
-      $theme_settings[$new] = $theme_settings[$old];
-      unset($theme_settings[$old]);
-      variable_set('theme_settings', $theme_settings);
-    }
+      $theme_settings = variable_get('theme_settings', array());
+      if (isset($theme_settings[$old])) {
+        $theme_settings[$new] = $theme_settings[$old];
+        unset($theme_settings[$old]);
+        variable_set('theme_settings', $theme_settings);
+      }
+      break;
   }
 }
 
Index: modules/taxonomy/taxonomy.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/taxonomy/taxonomy.module,v
retrieving revision 1.344
diff -u -d -F^\s*function -r1.344 taxonomy.module
--- modules/taxonomy/taxonomy.module	27 Mar 2007 05:13:54 -0000	1.344
+++ modules/taxonomy/taxonomy.module	3 Apr 2007 21:42:36 -0000
@@ -885,11 +885,13 @@ function taxonomy_node_delete_revision($
  * Implementation of hook_node_type().
  */
 function taxonomy_node_type($op, $info) {
-  if ($op == 'update' && !empty($info->old_type) && $info->type != $info->old_type) {
-    db_query("UPDATE {vocabulary_node_types} SET type = '%s' WHERE type = '%s'", $info->type, $info->old_type);
-  }
-  elseif ($op == 'delete') {
-    db_query("DELETE FROM {vocabulary_node_types} WHERE type = '%s'", $info->type);
+  switch ($op) {
+    case 'rename':
+      db_query("UPDATE {vocabulary_node_types} SET type = '%s' WHERE type = '%s'", $info->type, $info->old_type);
+      break;
+    case 'delete':
+      db_query("DELETE FROM {vocabulary_node_types} WHERE type = '%s'", $info->type);
+      break;
   }
 }
 
Index: modules/upload/upload.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/upload/upload.module,v
retrieving revision 1.156
diff -u -d -F^\s*function -r1.156 upload.module
--- modules/upload/upload.module	27 Mar 2007 05:13:54 -0000	1.156
+++ modules/upload/upload.module	3 Apr 2007 21:42:38 -0000
@@ -338,14 +338,15 @@ function upload_form_alter(&$form, $form
     $form['workflow']['upload'] = array(
       '#type' => 'radios',
       '#title' => t('Attachments'),
-      '#default_value' => variable_get('upload_'. $form['#node_type']->type, 1),
+      '#default_value' => $form['#node_type']->settings['upload'],
       '#options' => array(t('Disabled'), t('Enabled')),
     );
   }
 
   if (isset($form['type']) && isset($form['#node'])) {
     $node = $form['#node'];
-    if ($form['type']['#value'] .'_node_form' == $form_id && variable_get("upload_$node->type", TRUE)) {
+    $type = node_get_types('type', $node);
+    if ($form['type']['#value'] .'_node_form' == $form_id && $type->settings['upload']) {
       drupal_add_js('misc/progress.js');
       drupal_add_js('misc/upload.js');
 
@@ -571,6 +572,19 @@ function upload_nodeapi(&$node, $op, $te
 }
 
 /**
+ * Implementation of hook_node_type().
+ */
+function upload_node_type($op, $info) {
+  switch ($op) {
+    case 'defaults':
+      return array(
+        'upload' => TRUE,
+      );
+      break;
+  }
+}
+
+/**
  * Displays file attachments in table
  */
 function theme_upload_attachments($files) {
Index: profiles/default/default.profile
===================================================================
RCS file: /cvs/drupal/drupal/profiles/default/default.profile,v
retrieving revision 1.8
diff -u -d -F^\s*function -r1.8 default.profile
--- profiles/default/default.profile	27 Mar 2007 05:13:54 -0000	1.8
+++ profiles/default/default.profile	3 Apr 2007 21:42:39 -0000
@@ -61,7 +61,7 @@ function default_profile_final() {
   );
 
   foreach ($types as $type) {
-    $type = (object) _node_type_set_defaults($type);
+    $type = _node_type_set_defaults((object) $type);
     node_type_save($type);
   }
 
