diff --git a/src/SeoObjectExtension.php b/src/SeoObjectExtension.php index 832b216..3415a5c 100644 --- a/src/SeoObjectExtension.php +++ b/src/SeoObjectExtension.php @@ -307,7 +307,7 @@ public function getSEOSocialLocale() * Attempt to find a suitable social image to use if one is not set. * By default try to see if this is a blog post and add the "Featured Image" * - * @return Image + * @return Image */ public function getSEOPreferedSocialImage() { @@ -808,7 +808,11 @@ public function getNumCharsTitle() { */ public function getPageContent() { - $response = Director::test($this->owner->Link()); + $session = []; + if (Controller::has_curr()) { + $session = Controller::curr()->getRequest()->getSession(); + } + $response = Director::test($this->owner->Link(), [], $session); if (!$response->isError()) { return $response->getBody();