0

I'm trying to remove the node access check from a view programmatically. But i'm not sure where the access tags are added/executed.

function MYMODYLE_views_query_alter(ViewExecutable $view, QueryPluginBase $query) {
kint($query);
}

If i print the $query the tags are empty, and i can't really figure out where or when those access tags are added. And how to manipulate them.

Can someone point me in the right direction?

Drupal: 8.3.2

0

Found it: MYMODULE_query_node_access_alter().

$query->condition contains al de realm conditions, these can be adjusted here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.