function FieldUninstallValidator::getFieldStoragesByModule
Same name in other branches
- 9 core/modules/field/src/FieldUninstallValidator.php \Drupal\field\FieldUninstallValidator::getFieldStoragesByModule()
- 8.9.x core/modules/field/src/FieldUninstallValidator.php \Drupal\field\FieldUninstallValidator::getFieldStoragesByModule()
- 10 core/modules/field/src/FieldUninstallValidator.php \Drupal\field\FieldUninstallValidator::getFieldStoragesByModule()
Returns all field storages for a specified module.
Parameters
string $module: The module to filter field storages by.
Return value
\Drupal\field\FieldStorageConfigInterface[] An array of field storages for a specified module.
1 call to FieldUninstallValidator::getFieldStoragesByModule()
- FieldUninstallValidator::validate in core/
modules/ field/ src/ FieldUninstallValidator.php - Determines the reasons a module can not be uninstalled.
File
-
core/
modules/ field/ src/ FieldUninstallValidator.php, line 94
Class
- FieldUninstallValidator
- Prevents uninstallation of modules providing active field storage.
Namespace
Drupal\fieldCode
protected function getFieldStoragesByModule($module) {
return $this->fieldStorageConfigStorage
->loadByProperties([
'module' => $module,
'include_deleted' => TRUE,
]);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.