Commit b79de5e4 authored by malaynayak's avatar malaynayak Committed by borisson_

Issue #3027215 by malaynayak, borisson_: Call to a member function getWidget()...

Issue #3027215 by malaynayak, borisson_: Call to a member function getWidget() on null in facets_theme_suggestions_facets_result_item
parent 04f2860f
......@@ -426,7 +426,9 @@ function facets_form_facets_facet_form_alter(&$form, FormStateInterface $form_st
function facets_theme_suggestions_facets_result_item(array $variables) {
$suggestions = [];
$facet = $variables['facet'];
$suggestions[] = 'facets_result_item__' . $facet->getWidget()['type'];
$suggestions[] = 'facets_result_item__' . $facet->getWidget()['type'] . '__' . $facet->id();
if ($facet instanceof FacetInterface) {
$suggestions[] = 'facets_result_item__' . $facet->getWidget()['type'];
$suggestions[] = 'facets_result_item__' . $facet->getWidget()['type'] . '__' . $facet->id();
}
return $suggestions;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment