mirror of
https://github.com/friendica/friendica
synced 2025-01-22 06:19:48 +00:00
Fix exception "Argument #2 ($jsonld) must be of type array, string given"
This commit is contained in:
parent
cd79d26ed5
commit
d42b31bee6
1 changed files with 2 additions and 1 deletions
|
@ -455,7 +455,8 @@ class ParseUrl
|
||||||
$list = $xpath->query("//script[@type='application/ld+json']");
|
$list = $xpath->query("//script[@type='application/ld+json']");
|
||||||
foreach ($list as $node) {
|
foreach ($list as $node) {
|
||||||
if (!empty($node->nodeValue)) {
|
if (!empty($node->nodeValue)) {
|
||||||
if ($jsonld = json_decode($node->nodeValue, true)) {
|
$jsonld = json_decode($node->nodeValue, true);
|
||||||
|
if (is_array($jsonld)) {
|
||||||
$siteinfo = self::parseParts($siteinfo, $jsonld);
|
$siteinfo = self::parseParts($siteinfo, $jsonld);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue