Browse Source

fixing popsu.theme bug 3

bach 2 years ago
parent
commit
94ed64640b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      web/themes/custom/popsu/popsu.theme

+ 1 - 1
web/themes/custom/popsu/popsu.theme

@@ -68,7 +68,7 @@ function popsu_preprocess_field(&$variables){
     if($element["#field_name"] == "field_programme"){
       foreach ($element["#items"]->getIterator() as $id => $item) {
         $nid = $item->getValue()['target_id'];
-        $variables['items'][$nid]['attributes']['class'] = new Attribute();
+        $variables['items'][$nid]['attributes'] = new Attribute();
         $variables['items'][$nid]['attributes']->addClass("programme-".$nid);
       }
     }