function node_limit_userofrole_node_limit_sql in Node Limit 8
Same name and namespace in other branches
- 7 node_limit_userofrole/node_limit_userofrole.module \node_limit_userofrole_node_limit_sql()
Implements hook_node_limit_sql().
File
- old/
node_limit_userofrole/ node_limit_userofrole.module, line 47 - Module to restrict the number of nodes by role.
Code
function node_limit_userofrole_node_limit_sql($lid, SelectQuery $select) {
global $user;
$limit = node_limit_userofrole_node_limit_load($lid);
if (empty($limit)) {
return;
}
$select
->condition('uid', $user->uid);
}