Issue #3020905 by kiamlaluno, johnwebdev: Remove the implementation example from the documentation for ModuleUninstallValidatorInterface::validate()

merge-requests/2419/head
xjm 2020-05-01 18:51:35 -05:00
parent ca7abe1e11
commit 7a45330f42
1 changed files with 0 additions and 14 deletions

View File

@ -14,20 +14,6 @@ interface ModuleUninstallValidatorInterface {
/**
* Determines the reasons a module can not be uninstalled.
*
* Example implementation:
* @code
* public function validate($module) {
* $entity_types = $this->entityTypeManager->getDefinitions();
* $reasons = array();
* foreach ($entity_types as $entity_type) {
* if ($module == $entity_type->getProvider() && $entity_type instanceof ContentEntityTypeInterface && $this->entityTypeManager->getStorage($entity_type->id())->hasData()) {
* $reasons[] = $this->t('There is content for the entity type: @entity_type', array('@entity_type' => $entity_type->getLabel()));
* }
* }
* return $reasons;
* }
* @endcode
*
* @param string $module
* A module name.
*