diff options
author | Dries Buytaert <dries@buytaert.net> | 2007-12-28 10:47:59 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2007-12-28 10:47:59 +0000 |
commit | fc2805b30afb132d0f547038229da178884a9b2f (patch) | |
tree | 39da792b9250861b173c74196e774de916854c13 /includes | |
parent | 9b2bf38e836632e0395cd2673fc397dfcccc4630 (diff) | |
download | brdo-fc2805b30afb132d0f547038229da178884a9b2f.tar.gz brdo-fc2805b30afb132d0f547038229da178884a9b2f.tar.bz2 |
- Patch #204083 by pwolanin: PHPdoc improvement.
Diffstat (limited to 'includes')
-rw-r--r-- | includes/menu.inc | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/includes/menu.inc b/includes/menu.inc index 745323a2b..b28c7c433 100644 --- a/includes/menu.inc +++ b/includes/menu.inc @@ -605,7 +605,7 @@ function _menu_link_translate(&$item) { } _menu_check_access($item, $map); } - + // If the link title matches that of its router item, localize it. if (!empty($item['title']) && ($item['title'] == $item['link_title'])){ if (!empty($item['title_arguments']) && $item['title_callback'] == 't') { @@ -640,7 +640,9 @@ function _menu_link_translate(&$item) { * * menu_get_object() will provide you the current node on paths like node/5, * node/5/revisions/48 etc. menu_get_object('user') will give you the user - * account on user/5 etc. + * account on user/5 etc. Note - this function should never be called within a + * _to_arg function (like user_current_to_arg()) since this may result in an + * infinite recursion. * * @param $type * Type of the object. These appear in hook_menu definitons as %type. Core @@ -1516,8 +1518,11 @@ function menu_get_active_title() { } /** - * Get a menu link by its mlid, access checked and link translated for - * rendering. + * Get a menu link by its mlid, access checked and link translated for rendering. + * + * This function should never be called from within node_load() or any other + * function used as a menu object load function since an infinite recursion may + * occur. * * @param $mlid * The mlid of the menu item. |