From 5a55fe01c6670c6804e0bc00e50dabca6c45444c Mon Sep 17 00:00:00 2001 From: jpg Date: Sat, 10 Apr 2021 18:59:33 +0200 Subject: [PATCH] - `CURLOPT_SSL_VERIFYSTATUS` disabled by default. - Raise User-Agent version to match new version - Updated PHPUnit config file --- phpunit.xml | 42 ++++++++++++++++++++++-------------------- src/UriClient.php | 5 +---- 2 files changed, 23 insertions(+), 24 deletions(-) diff --git a/phpunit.xml b/phpunit.xml index ff6b47d..88143c0 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,22 +1,24 @@ - - - - - - - - - - tests - - - - - src - - - - - + + + + src + + + + + + + + + + + + + + tests + + + diff --git a/src/UriClient.php b/src/UriClient.php index 89d2bce..efd4ec0 100644 --- a/src/UriClient.php +++ b/src/UriClient.php @@ -23,7 +23,7 @@ class UriClient extends TxtClient /** * User-agent */ - const CURL_USER_AGENT = 'RobotsTxtParser-VIPnytt/2.0 (+https://github.com/VIPnytt/RobotsTxtParser/blob/master/README.md)'; + const CURL_USER_AGENT = 'RobotsTxtParser-VIPnytt/2.1 (+https://github.com/VIPnytt/RobotsTxtParser/blob/master/README.md)'; /** * Base uri @@ -123,9 +123,6 @@ private function request($options = []) ) ) ? CURLOPT_CAPATH : CURLOPT_CAINFO => $caPathOrFile ]); - if (PHP_VERSION_ID >= 70700) { - curl_setopt($curl, CURLOPT_SSL_VERIFYSTATUS, true); - } // Apply custom cURL options curl_setopt_array($curl, $options); // Initialize the header parser