[BUGFIX] Test for curl 72/49772/2
authorStefan Froemken <froemken@gmail.com>
Fri, 2 Sep 2016 16:33:43 +0000 (18:33 +0200)
committerPhilipp Gampe <philipp.gampe@typo3.org>
Sat, 3 Sep 2016 00:16:44 +0000 (02:16 +0200)
Currently we check for curl by the deprecated
setting curlUse.
With this patch we will check for curl
via function_exists

Resolves: #77794
Releases: master
Change-Id: I4502d0044f749be3f0934f2f76693f155f8339d7
Reviewed-on: https://review.typo3.org/49772
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Philipp Gampe <philipp.gampe@typo3.org>
Tested-by: Philipp Gampe <philipp.gampe@typo3.org>
typo3/sysext/install/Classes/SystemEnvironment/SetupCheck.php

index 00397bc..14c19c1 100644 (file)
@@ -83,7 +83,7 @@ class SetupCheck
     protected function checkDownloadsPossible()
     {
         $allowUrlFopen = (bool)ini_get('allow_url_fopen');
-        $curlEnabled = !empty($GLOBALS['TYPO3_CONF_VARS']['SYS']['curlUse']);
+        $curlEnabled = function_exists('curl_version');
         if ($allowUrlFopen || $curlEnabled) {
             $status = new Status\OkStatus();
             $status->setTitle('Fetching external URLs is allowed');
@@ -91,7 +91,7 @@ class SetupCheck
             $status = new Status\WarningStatus();
             $status->setTitle('Fetching external URLs is not allowed');
             $status->setMessage(
-                'Either enable PHP runtime setting "allow_url_fopen"' . LF . 'or enable curl by setting [SYS][curlUse] accordingly.'
+                'Either enable PHP runtime setting "allow_url_fopen"' . LF . 'or compile curl into your PHP with --with-curl.'
             );
         }