You are here

public function PremiumContent::getDatabase in Node Option Premium 8

Retrieves the database connection.

Return value

\Drupal\Core\Database\Connection The database connection.

File

src/Plugin/search_api/processor/PremiumContent.php, line 68

Class

PremiumContent
Adds premium information to the indexes.

Namespace

Drupal\nopremium\Plugin\search_api\processor

Code

public function getDatabase() {
  return $this->database ?: \Drupal::database();
}