function FilterUninstallValidator::getEnabledFilterFormats

Same name in other branches
  1. 9 core/modules/filter/src/FilterUninstallValidator.php \Drupal\filter\FilterUninstallValidator::getEnabledFilterFormats()
  2. 10 core/modules/filter/src/FilterUninstallValidator.php \Drupal\filter\FilterUninstallValidator::getEnabledFilterFormats()
  3. 11.x core/modules/filter/src/FilterUninstallValidator.php \Drupal\filter\FilterUninstallValidator::getEnabledFilterFormats()

Returns all enabled filter formats.

Return value

\Drupal\filter\FilterFormatInterface[]

1 call to FilterUninstallValidator::getEnabledFilterFormats()
FilterUninstallValidator::validate in core/modules/filter/src/FilterUninstallValidator.php
Determines the reasons a module can not be uninstalled.

File

core/modules/filter/src/FilterUninstallValidator.php, line 93

Class

FilterUninstallValidator
Prevents uninstallation of modules providing used filter plugins.

Namespace

Drupal\filter

Code

protected function getEnabledFilterFormats() {
    return $this->filterStorage
        ->loadByProperties([
        'status' => TRUE,
    ]);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.