function CheckProvider::setChecks
Same name in other branches
- 8.9.x core/lib/Drupal/Core/Access/CheckProvider.php \Drupal\Core\Access\CheckProvider::setChecks()
- 10 core/lib/Drupal/Core/Access/CheckProvider.php \Drupal\Core\Access\CheckProvider::setChecks()
- 11.x core/lib/Drupal/Core/Access/CheckProvider.php \Drupal\Core\Access\CheckProvider::setChecks()
Overrides CheckProviderInterface::setChecks
File
-
core/
lib/ Drupal/ Core/ Access/ CheckProvider.php, line 82
Class
- CheckProvider
- Loads access checkers from the container.
Namespace
Drupal\Core\AccessCode
public function setChecks(RouteCollection $routes) {
$this->loadDynamicRequirementMap();
foreach ($routes as $route) {
if ($checks = $this->applies($route)) {
$route->setOption('_access_checks', $checks);
}
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.