Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 8eafef1

Browse files
committed
show actual status code
1 parent 11535d5 commit 8eafef1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ZendDiagnostics/Check/GuzzleHttpService.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ public function check()
4848
{
4949
$response = $this->guzzle->get($this->url, $this->headers, $this->options)->send();
5050

51-
if ($this->statusCode !== $response->getStatusCode()) {
52-
return new Failure("Status code {$this->statusCode} does not match response from {$this->url}");
51+
if ($this->statusCode !== $statusCode = $response->getStatusCode()) {
52+
return new Failure("Status code {$this->statusCode} does not match {$statusCode} in response from {$this->url}");
5353
}
5454

5555
if ($this->content && (false === strpos($response->getBody(true), $this->content))) {

0 commit comments

Comments
 (0)