From d3b3fa9db60246ad3b7932afd3e4910e3fcd3bc1 Mon Sep 17 00:00:00 2001 From: Kent Rasmussen Date: Thu, 9 Jan 2025 13:29:31 +0900 Subject: [PATCH] refactor: Configuration can also be null reduces the number of PHP 8.4 deprecation warnings --- swagger-config/marketing/php/templates/api.mustache | 2 +- swagger-config/transactional/php/templates/api.mustache | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/swagger-config/marketing/php/templates/api.mustache b/swagger-config/marketing/php/templates/api.mustache index eeae621..9bc4054 100644 --- a/swagger-config/marketing/php/templates/api.mustache +++ b/swagger-config/marketing/php/templates/api.mustache @@ -37,7 +37,7 @@ use {{invokerPackage}}\ObjectSerializer; protected $config; protected $headerSelector; - public function __construct(Configuration $config = null) + public function __construct(?Configuration $config = null) { $this->client = new Client([ 'defaults' => [ diff --git a/swagger-config/transactional/php/templates/api.mustache b/swagger-config/transactional/php/templates/api.mustache index 4e2508d..57a4f37 100644 --- a/swagger-config/transactional/php/templates/api.mustache +++ b/swagger-config/transactional/php/templates/api.mustache @@ -36,7 +36,7 @@ use {{invokerPackage}}\ObjectSerializer; { protected $config; - public function __construct(Configuration $config = null) + public function __construct(?Configuration $config = null) { $this->config = $config ?: new Configuration(); }