public function MultipleRegistrationController::access in Multiple Registration 8
Same name and namespace in other branches
- 8.2 src/Controller/MultipleRegistrationController.php \Drupal\multiple_registration\Controller\MultipleRegistrationController::access()
- 3.x src/Controller/MultipleRegistrationController.php \Drupal\multiple_registration\Controller\MultipleRegistrationController::access()
Checks access for register page.
Parameters
\Drupal\Core\Session\AccountInterface $account: Run access checks for this account.
Return value
\Drupal\Core\Access\AccessResult Returns access result.
1 string reference to 'MultipleRegistrationController::access'
File
- src/
Controller/ MultipleRegistrationController.php, line 76
Class
- MultipleRegistrationController
- Class MultipleRegistrationController.
Namespace
Drupal\multiple_registration\ControllerCode
public function access(AccountInterface $account) {
$registerAccessCheck = new RegisterAccessCheck();
return AccessResult::allowedIf($account
->hasPermission('administer multiple_registration') || $registerAccessCheck
->access($account)
->isAllowed());
}