Commit 576c6080 authored by Steven Wittens's avatar Steven Wittens
Browse files

- #19405: Fix SQL in comment block for anonymous users.

parent 571369c6
......@@ -1982,7 +1982,7 @@ function node_access_view_all_nodes() {
*/
function node_db_rewrite_sql($query, $primary_table, $primary_field) {
if ($primary_field == 'nid' && !node_access_view_all_nodes()) {
$return['join'] = _node_access_join_sql();
$return['join'] = _node_access_join_sql($primary_table);
$return['where'] = _node_access_where_sql();
$return['distinct'] = 1;
return $return;
......
......@@ -1982,7 +1982,7 @@ function node_access_view_all_nodes() {
*/
function node_db_rewrite_sql($query, $primary_table, $primary_field) {
if ($primary_field == 'nid' && !node_access_view_all_nodes()) {
$return['join'] = _node_access_join_sql();
$return['join'] = _node_access_join_sql($primary_table);
$return['where'] = _node_access_where_sql();
$return['distinct'] = 1;
return $return;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment