From d6c8c2879ba391e8b08461fd5e19b6a10e07a1cc Mon Sep 17 00:00:00 2001 From: Zach Borboa Date: Tue, 20 Aug 2024 22:09:03 -0400 Subject: [PATCH 1/2] Use nullable type declaration as supported in versions >= PHP 7.1 (#882) --- src/Curl/CaseInsensitiveArray.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/Curl/CaseInsensitiveArray.php b/src/Curl/CaseInsensitiveArray.php index 3a4e1dbbae..e12901775e 100644 --- a/src/Curl/CaseInsensitiveArray.php +++ b/src/Curl/CaseInsensitiveArray.php @@ -42,12 +42,7 @@ class CaseInsensitiveArray implements \ArrayAccess, \Countable, \Iterator * @param mixed[] $initial (optional) Existing array to convert. * @return CaseInsensitiveArray */ - // TODO: Use a nullable type declaration when supported versions >= PHP 7.1. - // Trying to use the nullable type declaration on PHP 7.0: - // public function __construct(?array $initial = null) - // results in: - // ParseError: syntax error, unexpected '?', expecting variable (T_VARIABLE) - public function __construct($initial = null) + public function __construct(?array $initial = null) { if ($initial !== null) { foreach ($initial as $key => $value) { From 3fbd244703d126fbabef6ef1904135ae79796bf9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 21 Aug 2024 18:03:41 +0000 Subject: [PATCH 2/2] =?UTF-8?q?Bump=20version:=2010.0.0=20=E2=86=92=2010.0?= =?UTF-8?q?.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 4 ++++ src/Curl/Curl.php | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b52061cc90..194f7881c7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ backwards-incompatible changes that will affect existing usage. +## 10.0.1 - 2024-08-21 + +- Use nullable type declaration ([#882](https://github.com/php-curl-class/php-curl-class/pull/882)) + ## 10.0.0 - 2024-08-20 - Drop support for PHP 7.0 ([#880](https://github.com/php-curl-class/php-curl-class/pull/880)) diff --git a/src/Curl/Curl.php b/src/Curl/Curl.php index 5022be0783..427c7008e7 100644 --- a/src/Curl/Curl.php +++ b/src/Curl/Curl.php @@ -6,7 +6,7 @@ class Curl extends BaseCurl { - public const VERSION = '10.0.0'; + public const VERSION = '10.0.1'; public const DEFAULT_TIMEOUT = 30; public $curl = null;