protected function BackgroundImageAccessControlHandler::checkCreateAccess in Background Image 8
Same name and namespace in other branches
- 2.x src/BackgroundImageAccessControlHandler.php \Drupal\background_image\BackgroundImageAccessControlHandler::checkCreateAccess()
- 2.0.x src/BackgroundImageAccessControlHandler.php \Drupal\background_image\BackgroundImageAccessControlHandler::checkCreateAccess()
Separate from the checkAccess because the entity does not yet exist, it will be created during the 'add' process.
Overrides EntityAccessControlHandler::checkCreateAccess
File
- src/
BackgroundImageAccessControlHandler.php, line 51
Class
- BackgroundImageAccessControlHandler
- Access controller for the Background Image entity.
Namespace
Drupal\background_imageCode
protected function checkCreateAccess(AccountInterface $account, array $context, $entity_bundle = NULL) {
return AccessResult::allowedIfHasPermission($account, 'add background image');
}