You are here

function revisioning_events_argument_current_revision_author in Revisioning 7

Same name and namespace in other branches
  1. 6.4 revisioning.rules.inc \revisioning_events_argument_current_revision_author()
  2. 6.3 revisioning.rules.inc \revisioning_events_argument_current_revision_author()

File

./revisioning.rules.inc, line 136
Rules integration for Revisioning module.

Code

function revisioning_events_argument_current_revision_author($arguments, $name, $info) {
  $node = $arguments['node'];
  $current_vid = $node->current_revision_id;
  if ($node->vid != $current_vid) {
    $current = node_load($node->nid, $current_vid);
    return user_load($current->revision_uid);
  }
  return user_load($node->revision_uid);
}