Fix PHP8.0 error Cannot access offset of type string on string

This commit is contained in:
Hadi Nategh 2021-11-15 12:09:36 +01:00
parent 11e7683762
commit 379eb053a3

View File

@ -94,7 +94,7 @@ class home_favorite_portlet extends home_portlet
$need_reload = true;
}
$this->favorite = $context['favorite'];
$this->favorite = (array)$context['favorite'];
$this->title = lang($context['appname']) . ': ' . $this->favorite['name'];
$this->context = $context;
if($this->favorite)