Skip to content

Commit 57da874

Browse files
committed
Remove Expect: header when empty POST/PUT body
1 parent 4e43ece commit 57da874

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/WebDriver/Service/CurlService.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ public function execute($requestMethod, $url, $parameters = null, $extraOptions
5454
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($parameters));
5555
} else {
5656
$customHeaders[] = 'Content-Length: 0';
57+
$customHeaders[] = 'Expect:';
5758
}
5859

5960
curl_setopt($curl, CURLOPT_POST, true);
@@ -68,6 +69,7 @@ public function execute($requestMethod, $url, $parameters = null, $extraOptions
6869
curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($parameters));
6970
} else {
7071
$customHeaders[] = 'Content-Length: 0';
72+
$customHeaders[] = 'Expect:';
7173
}
7274

7375
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'PUT');

0 commit comments

Comments
 (0)