diff --git a/web/themes/custom/geofresco/geofresco.theme b/web/themes/custom/geofresco/geofresco.theme index 06a7f2c..97ec8c5 100644 --- a/web/themes/custom/geofresco/geofresco.theme +++ b/web/themes/custom/geofresco/geofresco.theme @@ -16,7 +16,7 @@ function geofresco_preprocess_page_title(&$variables) { return; } $string = isset($variables['title']['#markup']) ? $variables['title']['#markup'] : FALSE; - if ($string && $pos = strpos($string, "'s blog", -7)) { + if ($string && strlen($string) > 7 && $pos = strpos($string, "'s blog", -7)) { $uid = substr($string, 0, $pos); if (is_numeric($uid) && $account = \Drupal\user\Entity\User::load($uid)) { $variables['title'] = [