function workbench_moderation_node_live_load in Workbench Moderation 7.3
Same name and namespace in other branches
- 7 workbench_moderation.module \workbench_moderation_node_live_load()
Utility function to load the live revision of a node.
This is encapsulated so that changes to how the moderation data is stored will not impact the API.
Parameters
$node: The node being acted upon.
Return value
The node object of the live revision.
File
- ./
workbench_moderation.module, line 1353 - Content moderation for Workbench.
Code
function workbench_moderation_node_live_load($node) {
// Is there a live revision of this node?
if (isset($node->workbench_moderation['published']->vid)) {
return node_load($node->nid, $node->workbench_moderation['published']->vid);
}
}