function None::alterRouteDefinition

Same name in other branches
  1. 9 core/modules/views/src/Plugin/views/access/None.php \Drupal\views\Plugin\views\access\None::alterRouteDefinition()
  2. 8.9.x core/modules/views/src/Plugin/views/access/None.php \Drupal\views\Plugin\views\access\None::alterRouteDefinition()
  3. 10 core/modules/views/src/Plugin/views/access/None.php \Drupal\views\Plugin\views\access\None::alterRouteDefinition()

Overrides AccessPluginBase::alterRouteDefinition

File

core/modules/views/src/Plugin/views/access/None.php, line 40

Class

None
Access plugin that provides no access control at all.

Namespace

Drupal\views\Plugin\views\access

Code

public function alterRouteDefinition(Route $route) {
    $route->setRequirement('_access', 'TRUE');
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.