diff --git a/changelog.txt b/changelog.txt index 86036ef9fe743e5897aa56bdefa25426525f0a56..bac951e2ac1a67f26e0bac3d6c2b268de7df6507 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,5 +1,8 @@ += 1.0.4 - 2020-12-09 = +* Fixed issue with body + = 1.0.3 - 2020-04-10 = -* Increased Curl connection timeout +* Increased Curl connection timeout = 1.0.2 - 2019-12-06 = * Fixed issue with headers diff --git a/src/Curl/CurlClient.php b/src/Curl/CurlClient.php index 503b3177ae77c6d0e433a9bfb09708a53c5bdae1..ace05988d1d6f783d2ec7577a6f00bdef4b3006d 100644 --- a/src/Curl/CurlClient.php +++ b/src/Curl/CurlClient.php @@ -91,7 +91,7 @@ class CurlClient implements HttpClient { return $len; } ]; - if ( $method !== "GET" ) { + if ( ! empty( $body ) ) { $options[ \CURLOPT_POSTFIELDS ] = $body; } \curl_setopt_array( $this->curlResource, $options );