Skip to content

Commit 8820baa

Browse files
authored
Merge pull request #36 from mr-ransel/master
Update Curl.php false header count error
2 parents 5ca14e8 + fef57f1 commit 8820baa

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/Bart/Curl.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -186,11 +186,9 @@ private function request($httpMethod, $path, array $getParams, $body, array $hea
186186
array_shift($pieces);
187187
}
188188

189-
$headerCount = count($pieces);
190-
if ($headerCount != 2) {
191-
throw new \Exception("Curl got more or less headers ($headerCount) than it knows how to deal with");
192-
}
193-
189+
190+
191+
194192
// grab the headers section
195193
$responseArray['headers'] = $this->parseHeaders(array_shift($pieces));
196194
//combine the rest of the pieces, there could be line breaks in the body

0 commit comments

Comments
 (0)