diff --git a/elements/ContentGalleryTags.php b/elements/ContentGalleryTags.php index 44dd000..8b90ca9 100644 --- a/elements/ContentGalleryTags.php +++ b/elements/ContentGalleryTags.php @@ -72,17 +72,16 @@ public function compile() /** * Add an image to a template * - * @param object $template The template object to add the image to - * @param array $rowData The element or module as array - * @param integer|null $maxWidth An optional maximum width of the image - * @param string|null $lightboxGroupIdentifier An optional lightbox group identifier - * @param FilesModel|null $filesModel An optional files model + * @param object $objTemplate The template object to add the image to + * @param array $arrItem The element or module as array + * @param integer $intMaxWidth An optional maximum width of the image + * @param string $strLightboxId An optional lightbox ID */ - public static function addImageToTemplate($template, array $rowData, $maxWidth = null, $lightboxGroupIdentifier = null, FilesModel $filesModel = null): void + public static function addImageToTemplate($objTemplate, $arrItem, $intMaxWidth=null, $strLightboxId=null) { - Controller::addImageToTemplate($template, $rowData, $maxWidth, $lightboxGroupIdentifier, $filesModel); + Controller::addImageToTemplate($objTemplate, $arrItem, $intMaxWidth, $strLightboxId); if (TL_MODE == 'FE') { - $found = \TagModel::findByIdAndTable($rowData['id'], 'tl_files'); + $found = \TagModel::findByIdAndTable($arrItem['id'], 'tl_files'); $tags = array(); if ($found && $found->count()) { while ($found->next()) { diff --git a/modules/ModuleEventReaderTags.php b/modules/ModuleEventReaderTags.php index 584a131..f2c1cf8 100644 --- a/modules/ModuleEventReaderTags.php +++ b/modules/ModuleEventReaderTags.php @@ -279,7 +279,7 @@ protected function compile() } $arrEvent['singleSRC'] = $objModel->path; - $this->addImageToTemplate($objTemplate, $arrEvent, null, null, $objModel); + $this->addImageToTemplate($objTemplate, $arrEvent, null, null); } } diff --git a/modules/ModuleEventlistTags.php b/modules/ModuleEventlistTags.php index cee921f..a285a8b 100644 --- a/modules/ModuleEventlistTags.php +++ b/modules/ModuleEventlistTags.php @@ -354,7 +354,7 @@ protected function compile() } $event['singleSRC'] = $objModel->path; - $this->addImageToTemplate($objTemplate, $event, null, null, $objModel); + $this->addImageToTemplate($objTemplate, $event, null, null); // Link to the event if no image link has been defined if (!$objTemplate->fullsize && !$objTemplate->imageUrl)