diff options
Diffstat (limited to 'modules/path/path.module')
-rw-r--r-- | modules/path/path.module | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/modules/path/path.module b/modules/path/path.module index bdc4b2ee5..449b72aba 100644 --- a/modules/path/path.module +++ b/modules/path/path.module @@ -135,12 +135,14 @@ function path_nodeapi_validate(&$node, $arg) { /** * Implementation of hook_nodeapi_load(). */ -function path_nodeapi_load(&$node, $arg) { - $language = isset($node->language) ? $node->language : ''; - $path = 'node/' . $node->nid; - $alias = drupal_get_path_alias($path, $language); - if ($path != $alias) { - $node->path = $alias; +function path_nodeapi_load($nodes, $types) { + foreach ($nodes as $node) { + $language = isset($node->language) ? $node->language : ''; + $path = 'node/' . $node->nid; + $alias = drupal_get_path_alias($path, $language); + if ($path != $alias) { + $node->path = $alias; + } } } |