[BUGFIX] Linkvalidator: Improve tolerance on HEAD-request error
[Packages/TYPO3.CMS.git] / typo3 / sysext / linkvalidator / Classes / Linktype / ExternalLinktype.php
index f36894e..fc2ca08 100644 (file)
@@ -74,9 +74,9 @@ class ExternalLinktype extends \TYPO3\CMS\Linkvalidator\Linktype\AbstractLinktyp
                try {
                        /** @var $response \HTTP_Request2_Response */
                        $response = $request->send();
-                       // HEAD was not allowed, now trying GET
                        $status = isset($response) ? $response->getStatus() : 0;
-                       if ($status === 405 || $status === 403) {
+                       // HEAD was not allowed or threw an error, now trying GET
+                       if ($status >= 400) {
                                $request->setMethod('GET');
                                $request->setHeader('Range', 'bytes = 0 - 4048');
                                /** @var $response \HTTP_Request2_Response */