diff options
Diffstat (limited to 'modules/node/node.module')
-rw-r--r-- | modules/node/node.module | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/modules/node/node.module b/modules/node/node.module index 8535a3d3f..68b33781d 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -3236,13 +3236,12 @@ function _node_query_node_access_alter($query, $base_table, $type) { if ($type == 'entity' && count($entity_conditions->conditions())) { // All the node access conditions are only for field values belonging to // nodes. - $etid = variable_get('field_sql_storage_node_etid'); - $entity_conditions->condition("$base_alias.etid", $etid); + $entity_conditions->condition("$base_alias.entity_type", 'node'); $or = db_or(); $or->condition($entity_conditions); // If the field value belongs to a non-node entity type then this function // does not do anything with it. - $or->condition("$base_alias.etid", $etid, '<>'); + $or->condition("$base_alias.entity_type", 'node', '<>'); // Add the compiled set of rules to the query. $query->condition($or); } |