New answers tagged

0

This is what I use for Drupal 8. use Drupal\Core\Session\AccountInterface; /** * Utility function that checks for single or multiple roles. * * @param string or array $roles * The role(s) to check. * * @param AccountInterface $account * The user to check * * @return bool * Whether the account has ...


Top 50 recent answers are included