Skip to content
Snippets Groups Projects
Commit a941c922 authored by Markus Kalkbrenner's avatar Markus Kalkbrenner Committed by Joris Vercammen
Browse files

Issue #3199156 by mkalkbrenner: Drupal site install from existing config is broken

parent 5ef2c7c3
No related branches found
Tags 8.x-1.7
No related merge requests found
......@@ -49,6 +49,12 @@ class SearchApiSubscriber implements EventSubscriberInterface {
* {@inheritdoc}
*/
public static function getSubscribedEvents() {
// Workaround to avoid a fatal error during site install from existing config.
// @see https://www.drupal.org/project/facets/issues/3199156
if (!class_exists('\Drupal\search_api\Event\SearchApiEvents', TRUE)) {
return [];
}
return [
SearchApiEvents::QUERY_PRE_EXECUTE => 'queryAlter',
];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment