summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/node/content_types.inc5
1 files changed, 1 insertions, 4 deletions
diff --git a/modules/node/content_types.inc b/modules/node/content_types.inc
index 90ea9cace..0d8d0adec 100644
--- a/modules/node/content_types.inc
+++ b/modules/node/content_types.inc
@@ -223,9 +223,6 @@ function node_type_form_validate($form, &$form_state) {
// Work out what the type was before the user submitted this form
$old_type = trim($form_state['values']['old_type']);
- if (empty($old_type)) {
- $old_type = $type->type;
- }
$types = node_get_types('names');
@@ -245,7 +242,7 @@ function node_type_form_validate($form, &$form_state) {
$names = array_flip($types);
if (isset($names[$type->name]) && $names[$type->name] != $old_type) {
- form_set_error('name', t('The human-readable name %name is already taken.', array('%name' => $names[$type->name])));
+ form_set_error('name', t('The human-readable name %name is already taken.', array('%name' => $type->name)));
}
}