You are here

public function None::alterRouteDefinition in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/views/src/Plugin/views/access/None.php \Drupal\views\Plugin\views\access\None::alterRouteDefinition()

Allows access plugins to alter the route definition of a view.

Likely the access plugin will add new requirements, so its custom access checker can be applied.

Parameters

\Symfony\Component\Routing\Route $route: The route to change.

Overrides AccessPluginBase::alterRouteDefinition

File

core/modules/views/src/Plugin/views/access/None.php, line 44
Contains \Drupal\views\Plugin\views\access\None.

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');
}