@@ -59,7 +59,7 @@ class JiraClient
5959 *
6060 * @throws JiraException
6161 */
62- public function __construct (ConfigurationInterface $ configuration = null , LoggerInterface $ logger = null , string $ path = './ ' )
62+ public function __construct (? ConfigurationInterface $ configuration = null , ? LoggerInterface $ logger = null , string $ path = './ ' )
6363 {
6464 if ($ configuration === null ) {
6565 if (!file_exists ($ path .'.env ' )) {
@@ -186,7 +186,7 @@ protected function filterNullVariable(array $haystack): array
186186 *
187187 * @return string|bool
188188 */
189- public function exec (string $ context , array |string $ post_data = null , string $ custom_request = null , string $ cookieFile = null ): string |bool
189+ public function exec (string $ context , array |string | null $ post_data = null , ? string $ custom_request = null , ? string $ cookieFile = null ): string |bool
190190 {
191191 $ url = $ this ->createUrlByContext ($ context );
192192
@@ -236,8 +236,8 @@ public function exec(string $context, array|string $post_data = null, string $cu
236236 curl_setopt ($ ch , CURLOPT_FOLLOWLOCATION , true );
237237 }
238238
239- // See https://github.com/php/php-src/issues/14184
240- // curl_setopt($ch, CURLOPT_ENCODING, '');
239+ // See https://github.com/php/php-src/issues/14184
240+ // curl_setopt($ch, CURLOPT_ENCODING, '');
241241
242242 curl_setopt (
243243 $ ch ,
@@ -405,7 +405,7 @@ protected function createUrlByContext(string $context): string
405405 /**
406406 * Add authorize to curl request.
407407 */
408- protected function authorization (\CurlHandle $ ch , array &$ curl_http_headers , string $ cookieFile = null ): void
408+ protected function authorization (\CurlHandle $ ch , array &$ curl_http_headers , ? string $ cookieFile = null ): void
409409 {
410410 // use cookie
411411 if ($ this ->getConfiguration ()->isCookieAuthorizationEnabled ()) {
@@ -472,7 +472,7 @@ public function toHttpQueryParameter(array $paramArray): string
472472 /**
473473 * download and save into outDir.
474474 */
475- public function download (string $ url , string $ outDir , string $ file , string $ cookieFile = null ): mixed
475+ public function download (string $ url , string $ outDir , string $ file , ? string $ cookieFile = null ): mixed
476476 {
477477 $ curl_http_header = [
478478 'Accept: */* ' ,
0 commit comments