Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
function menu_local_tasks($level = 0) {
...
if (isset($data['tabs'][$level])) {
return array(
'tabs' => $data['tabs'][$level],
'actions' => $data['actions'],
'root_path' => $root_path,
);
}
// @todo If there are no tabs, there can still be actions!
elseif (!empty($data['actions']['output'])) {
return array('actions' => $data['actions']) + $empty;
}
return $empty;
}
Comments
Comment #1
pwolanin CreditAttribution: pwolanin commentedDid you actually observe this as a bug, or just from reading the code?
I think this would be a problem, for example, if there are actions at depth 3, but no tabs at depth 3?
Comment #2
sunYes, encountered as bug in #542658-72: Move action "tabs" out of local tasks
Sorry, should have linked to that issue.