/** * @return Closure */ private function getMetaReverseTransformFunction() { return function ($metaData) { $metaId = null ? null : (int) $metaData['id']; if ($metaId === null || !$this->meta[$metaId] instanceof Meta) { return new Meta($metaData['keywords'], $metaData['keywordsOverwrite'], $metaData['description'], $metaData['descriptionOverwrite'], $metaData['title'], $metaData['titleOverwrite'], $metaData['url'], $metaData['urlOverwrite'], array_key_exists('custom', $metaData) ? $metaData['custom'] : null, ['seo_index' => SEOIndex::fromString($metaData['SEOIndex']), 'seo_follow' => SEOFollow::fromString($metaData['SEOFollow'])], $metaData['id'] = $metaId); } $this->meta[$metaId]->update($metaData['keywords'], $metaData['keywordsOverwrite'], $metaData['description'], $metaData['descriptionOverwrite'], $metaData['title'], $metaData['titleOverwrite'], $metaData['url'], $metaData['urlOverwrite'], array_key_exists('custom', $metaData) ? $metaData['custom'] : null, ['seo_index' => SEOIndex::fromString($metaData['SEOIndex']), 'seo_follow' => SEOFollow::fromString($metaData['SEOFollow'])]); return $this->meta[$metaId]; }; }
/** * @return SEOFollow|null */ public function getSEOFollow() { if (!$this->hasSEOFollow()) { return; } return SEOFollow::fromString($this->data['seo_follow']); }