protected function PrivateMessageThreadAccessControlHandler::checkCreateAccess in Private Message 8
Same name and namespace in other branches
- 8.2 src/Entity/Access/PrivateMessageThreadAccessControlHandler.php \Drupal\private_message\Entity\Access\PrivateMessageThreadAccessControlHandler::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/
Entity/ Access/ PrivateMessageThreadAccessControlHandler.php, line 49
Class
- PrivateMessageThreadAccessControlHandler
- Access control handler for private message thread entities.
Namespace
Drupal\private_message\Entity\AccessCode
protected function checkCreateAccess(AccountInterface $account, array $context, $entity_bundle = NULL) {
return AccessResult::allowedIfHasPermission($account, 'use private messaging system');
}