Skip to content

Commit

Permalink
Update Curl.php false header count error
Browse files Browse the repository at this point in the history
I've been unable to reproduce the error state described here. I can also find no  record of curl having the described limitation
  • Loading branch information
mr-ransel authored Sep 19, 2017
1 parent 5ca14e8 commit fef57f1
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/Bart/Curl.php
Original file line number Diff line number Diff line change
Expand Up @@ -186,11 +186,9 @@ private function request($httpMethod, $path, array $getParams, $body, array $hea
array_shift($pieces);
}

$headerCount = count($pieces);
if ($headerCount != 2) {
throw new \Exception("Curl got more or less headers ($headerCount) than it knows how to deal with");
}




// grab the headers section
$responseArray['headers'] = $this->parseHeaders(array_shift($pieces));
//combine the rest of the pieces, there could be line breaks in the body
Expand Down

0 comments on commit fef57f1

Please sign in to comment.