Merge pull request #13977 from annando/dont-retry

Don't retry when fetching invalid content
This commit is contained in:
Tobias Diekershoff 2024-03-09 13:59:36 +01:00 committed by GitHub
commit 2077e00eae
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1611,15 +1611,15 @@ class Processor
if (empty($object) || !is_array($object)) {
Logger::notice('Invalid JSON data', ['url' => $url, 'content-type' => $curlResult->getContentType()]);
return '';
return null;
}
if (!self::isValidObject($object, $url)) {
return '';
return null;
}
if (!HTTPSignature::isValidContentType($curlResult->getContentType(), $url)) {
return '';
return null;
}
$ldobject = JsonLD::compact($object);