public function ContentAccess::getDatabase in Search API 8
Retrieves the database connection.
Return value
\Drupal\Core\Database\Connection The database connection.
File
- src/
Plugin/ search_api/ processor/ ContentAccess.php, line 74
Class
- ContentAccess
- Adds content access checks for nodes and comments.
Namespace
Drupal\search_api\Plugin\search_api\processorCode
public function getDatabase() {
return $this->database ?: \Drupal::database();
}