You are here

protected function WebformLibrariesManager::areElementsExcluded in Webform 6.x

Same name and namespace in other branches
  1. 8.5 src/WebformLibrariesManager.php \Drupal\webform\WebformLibrariesManager::areElementsExcluded()

Determine if a library's elements are excluded.

Parameters

array $elements: An array of element types.

Return value

bool TRUE if a library's elements are excluded.

1 call to WebformLibrariesManager::areElementsExcluded()
WebformLibrariesManager::initExcludedLibraries in src/WebformLibrariesManager.php
Initialize excluded libraries.

File

src/WebformLibrariesManager.php, line 610

Class

WebformLibrariesManager
Webform libraries manager.

Namespace

Drupal\webform

Code

protected function areElementsExcluded(array $elements) {
  $excluded_elements = $this->configFactory
    ->get('webform.settings')
    ->get('element.excluded_elements');
  if (!$excluded_elements) {
    return FALSE;
  }
  return WebformArrayHelper::keysExist($excluded_elements, $elements);
}