function node_activity_access_grants in Activity 7
Same name and namespace in other branches
- 6.2 modules/node.activity.inc \node_activity_access_grants()
Implementation of hook_activity_access_grants().
File
- modules/
node.activity.inc, line 26 - Provides Activity integration for the node module.
Code
function node_activity_access_grants($account) {
$grants = array();
// Select the nodes you have created.
$created_result = db_query("SELECT nid FROM {node} WHERE uid = :uid", array(
':uid' => $account->uid,
))
->fetchCol();
if (!empty($created_result)) {
$grants['node_author'] = $created_result;
}
return $grants;
}