summaryrefslogtreecommitdiff
path: root/modules/menu
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2009-10-17 00:51:53 +0000
committerDries Buytaert <dries@buytaert.net>2009-10-17 00:51:53 +0000
commita613c60fe1cb806d6db2493c5322a4fb08549724 (patch)
treeb1785e2d8ae0a8a27ea055b37392e32f3c173c13 /modules/menu
parenta09822b363813158a6182057917080b22d3ca8f7 (diff)
downloadbrdo-a613c60fe1cb806d6db2493c5322a4fb08549724.tar.gz
brdo-a613c60fe1cb806d6db2493c5322a4fb08549724.tar.bz2
- Patch #511286 by JacobSingh, David_Rothstein, dmitrig01, Gábor Hojtsy, ksenzee et al: add customizable shortcuts to the toolbar.
Diffstat (limited to 'modules/menu')
-rw-r--r--modules/menu/menu.module12
1 files changed, 2 insertions, 10 deletions
diff --git a/modules/menu/menu.module b/modules/menu/menu.module
index ac7c4248f..1e71297a5 100644
--- a/modules/menu/menu.module
+++ b/modules/menu/menu.module
@@ -271,21 +271,13 @@ function menu_save($menu) {
*
* @see menu_load()
*
- * _menu_delete_item() will take care of clearing the page cache. Other modules
+ * menu_delete_links() will take care of clearing the page cache. Other modules
* should take care of their menu-related data by implementing
* hook_menu_delete().
*/
function menu_delete($menu) {
// Delete all links from the menu.
- $links = db_query("SELECT * FROM {menu_links} WHERE menu_name = :menu_name", array(':menu_name' => $menu['menu_name']));
- foreach ($links as $link) {
- // To speed up the deletion process, we reset some link properties that
- // would trigger re-parenting logic in _menu_delete_item() and
- // _menu_update_parental_status().
- $link['has_children'] = FALSE;
- $link['plid'] = 0;
- _menu_delete_item($link);
- }
+ menu_delete_links($menu['menu_name']);
// Delete the custom menu.
db_delete('menu_custom')