You are here

protected function DisqusCommentsStatus::getEnabledTypes in Disqus 8

Gets content types Disqus is enabled for.

Return value

array Array of content type machine names.

1 call to DisqusCommentsStatus::getEnabledTypes()
DisqusCommentsStatus::query in src/Plugin/migrate/source/DisqusCommentsStatus.php

File

src/Plugin/migrate/source/DisqusCommentsStatus.php, line 35

Class

DisqusCommentsStatus
Disqus comments status.

Namespace

Drupal\disqus\Plugin\migrate\source

Code

protected function getEnabledTypes() {
  $enabled = $this
    ->getDatabase()
    ->select('variable', 'v')
    ->fields('v', [
    'value',
  ])
    ->condition('v.name', 'disqus_nodetypes')
    ->execute()
    ->fetchField();
  return array_filter(unserialize($enabled));
}