function lingotek_save_pathauto_alias in Lingotek Translation 7.6
Same name and namespace in other branches
- 7.7 lingotek.remote.inc \lingotek_save_pathauto_alias()
1 call to lingotek_save_pathauto_alias()
File
- ./
lingotek.remote.inc, line 279
Code
function lingotek_save_pathauto_alias($node, $langcode) {
module_load_include('inc', 'pathauto');
$uri = entity_uri('node', $node);
$node_unchanged = entity_load_unchanged('node', $node->nid);
pathauto_create_alias('node', 'update', $uri['path'], array(
'node' => clone $node_unchanged,
), $node->type, $langcode);
}