protected function SocialGroupSettings::hasPermission in Open Social 10.0.x
Same name and namespace in other branches
- 10.3.x modules/social_features/social_group/src/Form/SocialGroupSettings.php \Drupal\social_group\Form\SocialGroupSettings::hasPermission()
- 10.1.x modules/social_features/social_group/src/Form/SocialGroupSettings.php \Drupal\social_group\Form\SocialGroupSettings::hasPermission()
- 10.2.x modules/social_features/social_group/src/Form/SocialGroupSettings.php \Drupal\social_group\Form\SocialGroupSettings::hasPermission()
Check if permission is granted.
Parameters
string $name: The permission name.
Return value
bool TRUE if permission is granted.
1 call to SocialGroupSettings::hasPermission()
- SocialGroupSettings::buildForm in modules/
social_features/ social_group/ src/ Form/ SocialGroupSettings.php - Form constructor.
File
- modules/
social_features/ social_group/ src/ Form/ SocialGroupSettings.php, line 137
Class
- SocialGroupSettings
- Settings form which enables site managers to configure different options.
Namespace
Drupal\social_group\FormCode
protected function hasPermission($name) {
return !empty($this
->config('social_group.settings')
->get($name));
}