From 4ca53969eaa8fc05cef5a48fc077e5daacae38d3 Mon Sep 17 00:00:00 2001 From: Maksym Chubin <maksim.chubin@netzlabor.co> Date: Mon, 21 Jun 2021 14:46:32 +0300 Subject: [PATCH] [FIX] Add MenuItemPage title and subtitle type casting to string --- Classes/Domain/Model/MenuItemPage.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Classes/Domain/Model/MenuItemPage.php b/Classes/Domain/Model/MenuItemPage.php index f64b1a7..f3712eb 100644 --- a/Classes/Domain/Model/MenuItemPage.php +++ b/Classes/Domain/Model/MenuItemPage.php @@ -13,7 +13,7 @@ class MenuItemPage extends MenuItem */ public function getTitle(): string { - return $this->title ?: + return (string) $this->title ?: ObjectAccess::getPropertyPath($this, 'page.navTitle') ?: ObjectAccess::getPropertyPath($this, 'page.title'); } @@ -23,7 +23,7 @@ class MenuItemPage extends MenuItem */ public function getSubtitle(): string { - return $this->subtitle ?: + return (string) $this->subtitle ?: ObjectAccess::getPropertyPath($this, 'page.subtitle'); } } -- GitLab