From 8118bd0ed2ccd143ed35b730683fc43aac684c3f Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 31 Aug 2006 18:01:19 +0000 Subject: - Patch #81574 by assimmonds: deleting content types was broken. --- modules/node/content_types.inc | 8 ++++---- modules/node/node.module | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'modules') diff --git a/modules/node/content_types.inc b/modules/node/content_types.inc index 307346e12..e30871fd1 100644 --- a/modules/node/content_types.inc +++ b/modules/node/content_types.inc @@ -361,7 +361,7 @@ function node_type_reset(&$type) { /** * Menu callback; delete a single content type. */ -function node_type_delete($type) { +function node_type_delete_confirm($type) { $form['type'] = array('#type' => 'value', '#value' => $type->type); $form['name'] = array('#type' => 'value', '#value' => $type->name); @@ -375,13 +375,13 @@ function node_type_delete($type) { $caption .= '

'. t('This action cannot be undone.') .'

'; - return confirm_form('node_type_delete_form', $form, $message, 'admin/content/types', $caption, t('Delete')); + return confirm_form($form, $message, 'admin/content/types', $caption, t('Delete')); } /** - * Process content type delete form submissions. + * Process content type delete confirm submissions. */ -function node_type_delete_form_submit($form_id, $form_values) { +function node_type_delete_confirm_submit($form_id, $form_values) { db_query("DELETE FROM {node_type} WHERE type = '%s'", $form_values['type']); $t_args = array('%name' => $form_values['name']); diff --git a/modules/node/node.module b/modules/node/node.module index 1c92d03b9..764125020 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1130,7 +1130,7 @@ function node_menu($may_cache) { 'path' => 'admin/content/types/'. $type_url_str .'/delete', 'title' => t('delete'), 'callback' => 'drupal_get_form', - 'callback arguments' => array('node_type_delete', $type), + 'callback arguments' => array('node_type_delete_confirm', $type), 'type' => MENU_CALLBACK, ); } -- cgit v1.2.3