Skip to content

Commit

Permalink
Adding the missing Content-Type key in the headers for ES 5.3+ (rufli…
Browse files Browse the repository at this point in the history
  • Loading branch information
pengyue authored and ruflin committed May 22, 2017
1 parent fa694e0 commit d9c59b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Elastica/Transport/Http.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function exec(Request $request, array $params)
$content = str_replace('\/', '/', $content);
}

array_push($headers, $request->getContentType());
array_push($headers, sprintf('Content-Type: %s', $request->getContentType()));
if ($connection->hasCompression()) {
// Compress the body of the request ...
curl_setopt($conn, CURLOPT_POSTFIELDS, gzencode($content));
Expand Down

0 comments on commit d9c59b5

Please sign in to comment.