diff --git a/src/JiraClient.php b/src/JiraClient.php index 95b7b926..d29912c0 100644 --- a/src/JiraClient.php +++ b/src/JiraClient.php @@ -512,7 +512,7 @@ protected function authorization($ch, &$curl_http_headers, $cookieFile = null) } // if cookie file not exist, using id/pwd login - if (!file_exists($cookieFile)) { + if (!is_string($cookieFile) || !file_exists($cookieFile)) { if ($this->getConfiguration()->isTokenBasedAuth() === true) { $curl_http_headers[] = 'Authorization: Bearer '.$this->getConfiguration()->getPeronalAccessToken(); } else {