summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2004-07-13 07:10:56 +0000
committerDries Buytaert <dries@buytaert.net>2004-07-13 07:10:56 +0000
commit6477705fc86c50541f5ab3bb16cabb03cadb0ce5 (patch)
tree506e32cf9403c057edfd4c8a0d90cfcff6eb4342 /modules
parenta080ce5f0f4d6b7be1adf9d6057ce63566633a7c (diff)
downloadbrdo-6477705fc86c50541f5ab3bb16cabb03cadb0ce5.tar.gz
brdo-6477705fc86c50541f5ab3bb16cabb03cadb0ce5.tar.bz2
- Small code simplifications.
- Small usability improvement thanks to using drupal_goto() after deleting an alias.
Diffstat (limited to 'modules')
-rw-r--r--modules/path.module20
-rw-r--r--modules/path/path.module20
2 files changed, 6 insertions, 34 deletions
diff --git a/modules/path.module b/modules/path.module
index b4aedabc6..459533563 100644
--- a/modules/path.module
+++ b/modules/path.module
@@ -112,15 +112,9 @@ function path_admin_edit($pid = 0) {
* Menu callback; handles deletion of an URL alias.
*/
function path_admin_delete($pid = 0) {
- path_delete($pid);
- print theme('page', path_overview());
-}
-
-/**
- * Menu callback; presents the path-specific information from admin/help.
- */
-function path_admin_help() {
- print theme('page', path_help('admin/help#path'));
+ db_query('DELETE FROM {url_alias} WHERE pid = %d', $pid);
+ drupal_set_message(t('the alias has been deleted.'));
+ drupal_goto('admin/path');
}
/**
@@ -288,14 +282,6 @@ function path_load($pid) {
}
/**
- * Remove an URL alias from the database.
- */
-function path_delete($pid) {
- db_query('DELETE FROM {url_alias} WHERE pid = %d', $pid);
- drupal_set_message(t('the alias has been deleted.'));
-}
-
-/**
* Verify that a new URL alias is valid, and save it to the database.
*/
function path_save($edit) {
diff --git a/modules/path/path.module b/modules/path/path.module
index b4aedabc6..459533563 100644
--- a/modules/path/path.module
+++ b/modules/path/path.module
@@ -112,15 +112,9 @@ function path_admin_edit($pid = 0) {
* Menu callback; handles deletion of an URL alias.
*/
function path_admin_delete($pid = 0) {
- path_delete($pid);
- print theme('page', path_overview());
-}
-
-/**
- * Menu callback; presents the path-specific information from admin/help.
- */
-function path_admin_help() {
- print theme('page', path_help('admin/help#path'));
+ db_query('DELETE FROM {url_alias} WHERE pid = %d', $pid);
+ drupal_set_message(t('the alias has been deleted.'));
+ drupal_goto('admin/path');
}
/**
@@ -288,14 +282,6 @@ function path_load($pid) {
}
/**
- * Remove an URL alias from the database.
- */
-function path_delete($pid) {
- db_query('DELETE FROM {url_alias} WHERE pid = %d', $pid);
- drupal_set_message(t('the alias has been deleted.'));
-}
-
-/**
* Verify that a new URL alias is valid, and save it to the database.
*/
function path_save($edit) {