Added header

This commit is contained in:
Tobias Nyholm 2016-07-19 15:00:29 +02:00
parent 75614bf294
commit 1cdfc3c204

View File

@ -83,6 +83,7 @@ class RestClient
$headers['Content-Type'] = 'multipart/form-data; boundary='.$body->getBoundary();
} elseif (is_array($body)) {
$body = http_build_query($body);
$headers['Content-Type'] = 'application/x-www-form-urlencoded';
}
$request = new Request($method, $this->getApiUrl($uri), $headers, $body);