Commit 9a0cbf62 authored by Dries's avatar Dries
Browse files

- Patch #135926 by mooffie: hook_link is called by the wrong parameters. ...

- Patch #135926 by mooffie: hook_link is called by the wrong parameters.  Fixed disconnect between node_view() and hook_link().
parent fbde117d
...@@ -908,7 +908,7 @@ function node_delete($nid) { ...@@ -908,7 +908,7 @@ function node_delete($nid) {
* @param $node * @param $node
* A node array or node object. * A node array or node object.
* @param $teaser * @param $teaser
* Whether to display the teaser only, as on the main page. * Whether to display the teaser only or the full form.
* @param $page * @param $page
* Whether the node is being displayed by itself as a page. * Whether the node is being displayed by itself as a page.
* @param $links * @param $links
...@@ -923,7 +923,7 @@ function node_view($node, $teaser = FALSE, $page = FALSE, $links = TRUE) { ...@@ -923,7 +923,7 @@ function node_view($node, $teaser = FALSE, $page = FALSE, $links = TRUE) {
$node = node_build_content($node, $teaser, $page); $node = node_build_content($node, $teaser, $page);
if ($links) { if ($links) {
$node->links = module_invoke_all('link', 'node', $node, !$page); $node->links = module_invoke_all('link', 'node', $node, $teaser);
drupal_alter('link', $node->links, $node); drupal_alter('link', $node->links, $node);
} }
...@@ -1638,7 +1638,7 @@ function node_update_index() { ...@@ -1638,7 +1638,7 @@ function node_update_index() {
$node->build_mode = NODE_BUILD_SEARCH_INDEX; $node->build_mode = NODE_BUILD_SEARCH_INDEX;
$node = node_build_content($node, FALSE, FALSE); $node = node_build_content($node, FALSE, FALSE);
$node->body = drupal_render($node->content); $node->body = drupal_render($node->content);
// Allow modules to modify the fully-built node. // Allow modules to modify the fully-built node.
node_invoke_nodeapi($node, 'alter'); node_invoke_nodeapi($node, 'alter');
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment